I have ColdFusion 10 running on Windows Server 2008R2, using IIS7.5 as web server. I have an intranet application configured to use Windows Authentication with NTLM, which works very well. However, I have an issue with executing scheduled tasks. The files are part of this same application, but are located in a nested subdirectory under the webroot. On this subdirectory, I have turned off Windows Authentication and turned on Anonymous Authentication (using the built-in IUSR account).
When I try to run any .cfm files in this subdirectory via a scheduled task, I get a "401.2 - Unauthorized" error. However, if I run the files from a web browser, even when logged in as a non-domain user, the .cfm files run without issue.
I've checked the permissions on the subdirectory in question, and all of the relevant accounts (the Active Directory account CF runs under, the local account created for the application pool, and the built-in IUSR account) have permissions to read from that subdirectory.
I can't for the life of me figure out what I'm doing wrong. Anyone have any ideas?