IdentityCookieAuthenticationBuilderExtensions.AddTwoFactorUserIdCookie 方法

定义

添加用于双因素登录的标识 Cookie。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Options::OptionsBuilder<Microsoft::AspNetCore::Authentication::Cookies::CookieAuthenticationOptions ^> ^ AddTwoFactorUserIdCookie(Microsoft::AspNetCore::Authentication::AuthenticationBuilder ^ builder);
public static Microsoft.Extensions.Options.OptionsBuilder<Microsoft.AspNetCore.Authentication.Cookies.CookieAuthenticationOptions> AddTwoFactorUserIdCookie (this Microsoft.AspNetCore.Authentication.AuthenticationBuilder builder);
static member AddTwoFactorUserIdCookie : Microsoft.AspNetCore.Authentication.AuthenticationBuilder -> Microsoft.Extensions.Options.OptionsBuilder<Microsoft.AspNetCore.Authentication.Cookies.CookieAuthenticationOptions>
<Extension()>
Public Function AddTwoFactorUserIdCookie (builder As AuthenticationBuilder) As OptionsBuilder(Of CookieAuthenticationOptions)

参数

builder
AuthenticationBuilder

当前的 AuthenticationBuilder 实例。

返回

OptionsBuilder<TOptions>可用于配置 Cookie 身份验证的 。

适用于