Web Browser Management + Authentication

I am developing a Windows Phone 8 application that uses a WebBrowser control.

When I move my WebBrowser control to a website that has been tested with NTLM, nothing happens. The only event is Navigation, the control remains white, and neither the Navigation event nor the Navigation event are fired.

When I use the web browser system application to go to the same website, it displays a pop-up window asking me for a username, password and domain.

How can I achieve similar behavior with the WebBrowser control in my application?

+3
source share
2 answers

Ive HTTP-.

, - HEAD HTTP.

, - URI.

, WebException, e.Response.Headers WWW-Authenticate. , , .

WWW-Authenticate "basic", , . , HEAD, webClient.Credentials = NetworkCredential (, );

theyre OK, , , -, :

public static Uri addCredsToUri( Uri u, string user, string pass )
{
    UriBuilder uriSite = new UriBuilder( u );
    uriSite.UserName = user;
    uriSite.Password = pass;
    return uriSite.Uri;
}

, , WWW-Authenticate "", NTLM, , -. , , , NTLM .

+6

.

webbrowser navigate, postdata​​p >

-1

All Articles