Partager via


interface ICoreWebView2ClientCertificateRequestedEventArgs

interface ICoreWebView2ClientCertificateRequestedEventArgs
  : public IUnknown

Event args for the ClientCertificateRequested event.

Summary

Members Descriptions
get_AllowedCertificateAuthorities Returns the ICoreWebView2StringCollection.
get_Cancel You may set this flag to cancel the certificate selection.
get_Handled You may set this flag to TRUE to respond to the server with or without a certificate.
get_Host Host name of the server that requested client certificate authentication.
get_IsProxy Returns true if the server that issued this request is an http proxy.
get_MutuallyTrustedCertificates Returns the ICoreWebView2ClientCertificateCollection when client certificate authentication is requested.
get_Port Port of the server that requested client certificate authentication.
get_SelectedCertificate Returns the selected certificate.
GetDeferral Returns an ICoreWebView2Deferral object.
put_Cancel Sets the Cancel property.
put_Handled Sets the Handled property.
put_SelectedCertificate Sets the certificate to respond to the server.

Applies to

Product Introduced
WebView2 Win32 1.0.961.33
WebView2 Win32 Prerelease 1.0.955

Members

get_AllowedCertificateAuthorities

Returns the ICoreWebView2StringCollection.

public HRESULT get_AllowedCertificateAuthorities(ICoreWebView2StringCollection ** value)

The collection contains Base64 encoding of DER encoded distinguished names of certificate authorities allowed by the server.

get_Cancel

You may set this flag to cancel the certificate selection.

public HRESULT get_Cancel(BOOL * value)

If canceled, the request is aborted regardless of the Handled property. By default the value is FALSE.

get_Handled

You may set this flag to TRUE to respond to the server with or without a certificate.

public HRESULT get_Handled(BOOL * value)

If this flag is TRUE with a SelectedCertificate it responds to the server with the selected certificate otherwise respond to the server without a certificate. By default the value of Handled and Cancel are FALSE and display default client certificate selection dialog prompt to allow the user to choose a certificate. The SelectedCertificate is ignored unless Handled is set TRUE.

get_Host

Host name of the server that requested client certificate authentication.

public HRESULT get_Host(LPWSTR * value)

Normalization rules applied to the hostname are:

  • Convert to lowercase characters for ascii characters.

  • Punycode is used for representing non ascii characters.

  • Strip square brackets for IPV6 address.

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

get_IsProxy

Returns true if the server that issued this request is an http proxy.

public HRESULT get_IsProxy(BOOL * value)

Returns false if the server is the origin server.

get_MutuallyTrustedCertificates

Returns the ICoreWebView2ClientCertificateCollection when client certificate authentication is requested.

public HRESULT get_MutuallyTrustedCertificates(ICoreWebView2ClientCertificateCollection ** value)

The collection contains mutually trusted CA certificates.

get_Port

Port of the server that requested client certificate authentication.

public HRESULT get_Port(int * value)

get_SelectedCertificate

Returns the selected certificate.

public HRESULT get_SelectedCertificate(ICoreWebView2ClientCertificate ** value)

GetDeferral

Returns an ICoreWebView2Deferral object.

public HRESULT GetDeferral(ICoreWebView2Deferral ** deferral)

Use this operation to complete the event at a later time.

put_Cancel

Sets the Cancel property.

public HRESULT put_Cancel(BOOL value)

put_Handled

Sets the Handled property.

public HRESULT put_Handled(BOOL value)

put_SelectedCertificate

Sets the certificate to respond to the server.

public HRESULT put_SelectedCertificate(ICoreWebView2ClientCertificate * value)