Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am currently writing an application that connects to IIS server and spiders through the virtual directory to collection information. When I try to connect from a Windows XP SP3 with IIS 5.1 machine to a Windows Servers 2003 server with IIS 6.0 I get an "Access Denied" exception.

In the server's security event log it shows that I am trying to establish a connection as my local workstation's ASPNET account. I am an administrator on both machines and it does not seem to play a factor with trouble shooting the issue.

I posted this SO question on 4/1 and did not get anywhere. Maybe posting it on SF will provide better insight and trouble shooting.

share|improve this question
    
What kind of application is it? –  Joel Spolsky May 1 '09 at 2:59
    
It is a web application that can not connect to the remote IIS server. –  Michael Kniskern May 4 '09 at 17:17

1 Answer 1

In the discussion on StackOverflow you mentioned that it works when you run it as a standalone C# application, but not when you run it as a web application.

That makes sense. When you run it as a standalone C# application, it is running with your identity. When you run it through a web application, it is running using whatever identity you have configured for anonymous web requests under IIS, in this case, that local workstation's ASPNET account.

Depending on the security situation, you either want to

(1) configure the local web server so that that application serves anonymous web requests using a different account, one that has appropriate permissions on the server, or

(2) configure the local web server to not allow anonymous web requests. You will have to log on to the web page through your web browser using the username-password associated with an account that has appropriate permissions on the server

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.