Re: Default credentials

From: Hernan de Lahitte (hernan_at_lagash.com)
Date: 07/10/04


Date: Fri, 9 Jul 2004 19:34:12 -0300

If you need to pass certain credentials to your proxy WS class, just use
something like this:

CredentialCache cache = new CredentialCache();
cache.Add( new Uri( WSProxy.Url ), "Negotiate", new NetworkCredentials(
"youruser", "yourpwd", "yourdomain") );
WSProxy.Credentials = cache;

If you use NTLM auth in IIS, "Negotiate" will be fine. If you use "Basic"
auth instead, just put "Basic" where it says "negotiate".

-- 
Hernan de Lahitte
Lagash Systems S.A.
http://weblogs.asp.net/hernandl
This posting is provided "AS IS" with no warranties, and confers no rights.
"Wild Wind" <nobody@blackhole.com> wrote in message
news:2l7h6qF9ch05U1@uni-berlin.de...
> Hello,
>
> I have an application which calls a web service across the
> Internet from a client machine.
>
> The site that I have deployed the application to is such that
> to browse the Internet using a web browser, a person needs to
> do the following:
>
> (a) ensure that a proxy server address is specified;
>
> (b) enter a username and password into an authentication dialog
> that comes up whenever they start up the web browser.
>
> I am finding that as a result, I cannot connect at all to the
> Internet directly.
>
>
> I have deployed the same application on other sites that use
> a proxy server to connect to the Internet by specifying the
> proxy server address in my config file and using this address
> to create a proxy for the web service using the following code:
>
> Dim WSProxy as MyWebServiceProxy
> WSProxy.Proxy = New WebProxy(proxyServerAddresss, True, _
>  Nothing, CredentialCache.DefaultCredentials)
> WSProxy.CallWebServiceMethod()
>
> However, this works at client sites where I *don't* have to specify
> further authentication before web browsing. In other words, it
> *doesn't* work for the client site first mentioned above.
>
>
> My questions are:
>
> When someone supplies the authentication details when they want
> to use the web browser, are those details added to a CredentialCache?
>
> If so, can I get at this CredentialCache to get these credentials?
>
> If not, should I create my own credentials based on the username,
> password and domain that the user normally enters when accessing
> the web via a web browser?
>
> TIA,
>
> -- 
> Akin
>
> aknak at aksoto dot idps dot co dot uk
>
>
>


Relevant Pages

  • Re: Default credentials
    ... If you need to pass certain credentials to your proxy WS class, ... CredentialCache cache = new CredentialCache; ... > that comes up whenever they start up the web browser. ... this works at client sites where I *don't* have to specify ...
    (microsoft.public.dotnet.framework.webservices)
  • Re: Default credentials
    ... If you need to pass certain credentials to your proxy WS class, ... CredentialCache cache = new CredentialCache; ... > that comes up whenever they start up the web browser. ... this works at client sites where I *don't* have to specify ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • RE: bypassing proxy
    ... Depending on the web browser being used you can put in place a bypass, ... address and not forward the request to the proxy server. ... i am a security admin with a financial instituation, ... BigFix ...
    (Security-Basics)
  • Re: [opensuse] online update via squid
    ... Can you paste http://download.opensuse.org/update/11.0/ into a web browser ... the settings in yast2 proxy you may find the problem. ... to disable the proxy, put dns numbers and a gateway on the client, reboot, ... remove the online update repo, zypper clean, reboot, yast, online update ...
    (SuSE)
  • Proxy Override
    ... Currently we use the Proxy ... override settings in the user's web browser, ... if I choose automatic configuration ... We don't use the Firewall client and do not want to ...
    (microsoft.public.isa)