Currently i am able to hit to the proxy server by supplying username
and password after getting 407 response from proxy server. The server
is configure with authName =private which i get as Basic realm in the
server response. The config file contains:
# Proxy directive - asks for authentication when access a URL through
Allow from all
AuthName "Password Required"
Require user user
Require user valid-user
And i am setting the credential and getting the resonse from the
Uri proxy_url = new Uri("http://18.104.22.168:8080/");
proxy.Address = proxy_url;
proxy.Credentials = new NetworkCredential("user","pass","private");
httpWRequest.Proxy = proxy;
//get the response. This is where we make the connection to the server
httpWResponse = (HttpWebResponse)httpWRequest.GetResponse();
If i havent supplied "private" it is working fine, but if private is
supplied it is again fire 407 "AuthenticationRequired" error.
Can you tell me how to pass this realm value through credential in
C#.Net, if at all needed to pass?
Is the domain means the realm ? if yes why it is failing?
Here i am using basic authentication type.
Thanks in advance.
Bend of the road is not end of the road
Last Visit: 31-Dec-99 18:00 Last Update: 22-Jun-17 21:37