0

We have just deployed a asp.net project onto our testing server which was working fine on our development server. However once it was deployed to our testing server two pages (out of 10+) are generating 401 errors. The permissions on the pages that are returning the error are the same as the pages that are working.

  • The server it is running on is Windows Server 2008.
  • The web server we are using is IIS7.
  • We only allow anonymous authentication.

Update: While the two pages are consistently returning 401's it is now sporadically happening for other pages for short periods of time.

What could the possible reasons for this be?

2 Answers 2

0

I would suggest turning on logging of the status, substatus, and win32status in your IIS logs and post a line that shows the 401 error from the log here.

2
  • In all of the request the status is 401, the substatus is 0 and the win32 status is 0 as well.
    – Mike Lowen
    Sep 11, 2009 at 0:00
  • AFAIK, there is no 401.0 HTTP status code, so the substatus being 0 makes no sense to me. Trun off friendly HTTP error messages in your browser and post the browser error text here.
    – joeqwerty
    Sep 11, 2009 at 1:39
0

We were able to replicate the issue (as a bit of background the application is a REST like API) we found that if the first request to a page was a PUT call the page would return a 401 error and would continue to return that error. However if the first call to the page was a GET call the page would load fine and subsequent calls (either GET or PUT) would be successful for approximately an hour where the issue would arise again.

This we believe was caused by the application config taking precedence over the IIS7 config. Where IIS7 was configured for anonymous authentication the application was not. Once we configured the application to accept anonymous authentication the problem disappeared.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .