CoreWebView2ClientCertificateRequestedEventArgs Class

Event args for the CoreWebView2.ClientCertificateRequested event.

Summary

Members Description
AllowedCertificateAuthorities The list contains Base64 encoding of DER encoded distinguished names of certificate authorities allowed by the server.
Cancel Indicates whether to cancel the certificate selection.
Handled Indicates whether the event has been handled by host.
Host Returns host name of the server that requested client certificate authentication.
IsProxy Returns true if the server that issued this request is an http proxy. Returns false if the server is the origin server.
MutuallyTrustedCertificates Returns the list of CoreWebView2ClientCertificate when client certificate authentication is requested. The list contains mutually trusted CA certificate.
Port Returns port of the server that requested client certificate authentication.
SelectedCertificate Selected certificate to respond to the server.
GetDeferral Gets a Deferral object.

Properties

AllowedCertificateAuthorities

readonly IVectorView<string> AllowedCertificateAuthorities

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

Cancel

bool Cancel

Indicates whether to cancel the certificate selection. If canceled, the request is aborted regardless of the CoreWebView2ClientCertificateRequestedEventArgs.Handled property. By default the value is false.

Handled

bool Handled

Indicates whether the event has been handled by host. Set to true to respond to the server with or without a certificate. If this flag is true with a CoreWebView2ClientCertificateRequestedEventArgs.SelectedCertificate it responds to the server with the selected certificate otherwise respond to the server without a certificate. By default the value of CoreWebView2ClientCertificateRequestedEventArgs.Handled and CoreWebView2ClientCertificateRequestedEventArgs.Cancel are false and display default client certificate selection dialog prompt to allow the user to choose a certificate. The CoreWebView2ClientCertificateRequestedEventArgs.SelectedCertificate is ignored unless CoreWebView2ClientCertificateRequestedEventArgs.Handled is set to true.

Host

readonly string Host

Returns host name of the server that requested client certificate authentication. 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.

IsProxy

readonly bool IsProxy

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

MutuallyTrustedCertificates

readonly IVectorView<CoreWebView2ClientCertificate> MutuallyTrustedCertificates

Returns the list of CoreWebView2ClientCertificate when client certificate authentication is requested. The list contains mutually trusted CA certificate.

Port

readonly int Port

Returns port of the server that requested client certificate authentication.

SelectedCertificate

CoreWebView2ClientCertificate SelectedCertificate

Selected certificate to respond to the server.

Methods

GetDeferral

Deferral GetDeferral()

Gets a Deferral object. Use this to Complete the event at a later time.

Referenced by