共用方式為


CertificateAuthenticationEvents.OnCertificateValidated 屬性

定義

當憑證通過基本驗證,但可能需要自訂驗證時,就會叫用指派給此屬性的委派。

public:
 property Func<Microsoft::AspNetCore::Authentication::Certificate::CertificateValidatedContext ^, System::Threading::Tasks::Task ^> ^ OnCertificateValidated { Func<Microsoft::AspNetCore::Authentication::Certificate::CertificateValidatedContext ^, System::Threading::Tasks::Task ^> ^ get(); void set(Func<Microsoft::AspNetCore::Authentication::Certificate::CertificateValidatedContext ^, System::Threading::Tasks::Task ^> ^ value); };
public Func<Microsoft.AspNetCore.Authentication.Certificate.CertificateValidatedContext,System.Threading.Tasks.Task> OnCertificateValidated { get; set; }
member this.OnCertificateValidated : Func<Microsoft.AspNetCore.Authentication.Certificate.CertificateValidatedContext, System.Threading.Tasks.Task> with get, set
Public Property OnCertificateValidated As Func(Of CertificateValidatedContext, Task)

屬性值

備註

您必須提供這個屬性的委派,才能進行驗證。 在您的委派中,您應該從使用者詳細資料建構驗證主體,並將其附加至內容。Principal 屬性,最後呼叫內容。Success () ;

適用於