Search code examples
delphiiisfile-permissionsuac

File Write Access Denied from ISAPI


I'm using Delphi/Intraweb to build an ISAPI file. I'm using Win7 on my local machine and Server2012 as the target deployment. I created a "Temp" folder under the "cgi-bin" folder. I'm attempting to output files to the "Temp" folder.

If on the "Temp" folder grant "write" permissions to "Everyone" my file write works. So I know it's a permissions issue. But for some reason granting "write" permissions to "IIS_IUSRS" does not work.

How do I find out what user IIS is using to execute the cgi, and better yet how do I change it to be IIS_IUSRS as I would expect.

w3wp.exe is running under "DefaultAppPool". Granting write access to "DefaultAppPool" still does not give me write permissions to the Temp folder.


Solution

  • If I recall correctly, IIS versions on Windows 7 and Windows Server 2012 run the web application in an Application Pool and you can check/modify with the IIS administration console what user the w3wp.exe process(es) run(s) under in the Application Pool settings.