| kajKOsz 2005-07-28, 7:50 am |
| Hello,
enviroment:
Windows 2003 Web Edition + SP1
IIS 6.0
i have an intranet application (ASP.NET in C#) running on server
described above. IIS is set for NTLM authentication. application is set
for windows authetication and impersonating (in web.config)
[authentication mode="Windows" /]
[identity impersonate="true" /]
that application try to connect to a web service located on the same
web path, the path is provided by user (but still is the same as path
of main application). web reference is added to the project by VS and
proxy class is created automaticly. credentials are set to a default
credentials. when a web method [GetData()] is called on then proxy
class an exception is thrown: "The request failed with HTTP status 401:
Unauthorized.". this only happens on a production server, so i can't
debug it.
Proxy prx = new Proxy();
prx.Credentials = System.Net.CredentialCache.DefaultCredentials;
prx.Url = userURL;
prx.Getdata();
but, if user replaces the name of the server in url to "localhost" it
works !!
that's not all - when i install application on another server -
everything is OK
what configuration property of IIS controls behavior of credential
passing mechanism ??
i am very confused about that, can anyone help me ??
regards
Michal
|