Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"HTTP status 401: Access Denied" error for web service even when the virtual directory allows Anonymous access

i have a web service hosted on another server with the Anonymous Access CheckBox in IIS is already checked. when my local web application is trying to access the web service, i still get the "The request failed with HTTP status 401: Access Denied." error. my web application is calling the web service like the following:

MyObject.WebService ws = new MyObject.WebService (); ws.Retrieve(someParams);

what am i missing here?

like image 877
Gnot Avatar asked Oct 28 '08 01:10

Gnot


2 Answers

Make sure your directory permissions are also set to allow everyone read access. A lot of times doing local dev work I will forgot that the directory being accessed has a seperate set of permissions that need to be altered.

Cheers!

like image 29
thismat Avatar answered Oct 23 '22 15:10

thismat


Here is a good reference on diagnosing 401 errors.

From that, one place to start is looking at the credentials you configure for the anonymous user. If they are incorrect (if perhaps the user password was changed elsewhere) you will get an HTTP 401.

like image 192
David Hall Avatar answered Oct 23 '22 14:10

David Hall