IIS7.5 and .NET 4.0 FTPWebRequest

0

I'm having a difficult time getting FTP working in ASP.NET on IIS 7.5, Windows 2008 Server. This works in my development environment which is on Windows 7 also using IIS 7.5. It also works running the built in web server in VS2010.

I have a question open on Stack Overflow regarding this: https://stackoverflow.com/q/6530419/18893.

However, I am pretty sure it is some sort of permission issue. Can I change the user that the website runs under through the IIS MMC? If so, what kind of permissions should I have in order to transfer files with FTP? I don't think its a firewall issue, as when I log on through RDP as Administrator, I can send FTP files manually, which would do the same thing as the web user will be doing.

I need some help here, not getting any responses on the other site.

stephenbayer

Posted 2011-07-06T16:03:19.937

Reputation: 101

Answers

0

Ok, I couldn't get an answer to this for a week. I finally found how to change the user the website runs under. It is in the pools.

  1. Create new Application Pool
  2. Set the basic settings to .NET Framework 4.0.30319 framework version and "Integrated" Managed Pipeline mode. and check box for "Start application pool immediately".
  3. Create local user on system, give this user Read and Write access to the folders and sub folders of the website.
  4. Click on Application Pools again. the newly created application pool whatever it was named, in the right panel of the MMC click on Advanced Settings. Then set the "Identity" field to the newly created user.
  5. Click on the website, on the right panel click on "Basic Settings", in the dialog box set the Application Pool to the one that was created in the first step.
  6. Stop and Restart the website.

The FTPWebRequests are now working.

If anyone has any better solutions, please respond. If anyone feels this would open up security issues, also, please post more information.

stephenbayer

Posted 2011-07-06T16:03:19.937

Reputation: 101