Freigeben über


interface ICoreWebView2BasicAuthenticationRequestedEventArgs

interface ICoreWebView2BasicAuthenticationRequestedEventArgs
  : public IUnknown

Event args for the BasicAuthenticationRequested event.

Summary

Members Descriptions
get_Cancel Cancel the authentication request.
get_Challenge The authentication challenge string.
get_Response Response to the authentication request with credentials.
get_Uri The URI that led to the authentication challenge.
GetDeferral Returns an ICoreWebView2Deferral object.
put_Cancel Set the Cancel property.

Will contain the request that led to the HTTP authorization challenge, the challenge and allows the host to provide authentication response or cancel the request.

Applies to

Product Introduced
WebView2 Win32 1.0.1150.38
WebView2 Win32 Prerelease 1.0.1133

Members

get_Cancel

Cancel the authentication request.

public HRESULT get_Cancel(BOOL * cancel)

False by default. If set to true, Response will be ignored.

get_Challenge

The authentication challenge string.

public HRESULT get_Challenge(LPWSTR * challenge)

The caller must free the returned string with CoTaskMemFree. See API Conventions.

get_Response

Response to the authentication request with credentials.

public HRESULT get_Response(ICoreWebView2BasicAuthenticationResponse ** response)

This object will be populated by the app if the host would like to provide authentication credentials.

get_Uri

The URI that led to the authentication challenge.

public HRESULT get_Uri(LPWSTR * value)

For proxy authentication requests, this will be the URI of the proxy server.

The caller must free the returned string with CoTaskMemFree. See API Conventions.

GetDeferral

Returns an ICoreWebView2Deferral object.

public HRESULT GetDeferral(ICoreWebView2Deferral ** deferral)

Use this deferral to defer the decision to show the Basic Authentication dialog.

put_Cancel

Set the Cancel property.

public HRESULT put_Cancel(BOOL cancel)