views:

260

answers:

1

Hi,

my code is providing an access to our web service.

WebProxy proxy = new WebProxy(ProxyURL, ProxyPort); proxy.UseDefaultCredentials = false;

NetworkCredential nc = new NetworkCredential( ProxyLogin, ProxyPassword); proxy.Credentials = nc;

myWebService.Proxy = proxy;

My problem is that customer doesn't know ProxyLogin and ProxyPassword, especially if he is running Microsoft ISA server. Company policy doesn't allow him to know password and login.

Is there anyway to reach authorization information by code?

+3  A: 

There is no way to get password by code. If there was a way it would be a security vulnerability.

The user should have proxy access for his account. If he don't have, Than this is the end of it. If he has proxy access than your application should use his credentials.

proxy.UseDefaultCredentials = true;
Igal Serban