语言

MicrosoftIdentityConsentAndConditionalAccessHandler.ChallengeUser 方法

定义

强制用户同意特定范围并执行条件访问以获取特定声明。 在 Razor/Blazor 页或控制器上使用,在获取令牌之前主动确保范围和/或声明。 另一种机制HandleException(Exception)可确保Azure AD 在令牌获取尝试失败后请求的声明和范围。 有关详细信息,请参阅https://aka.ms/ms-id-web/ca_incremental-consent。

public void ChallengeUser(string[]? scopes, string? claims = default, string? userflow = default);
member this.ChallengeUser : string[] * string * string -> unit
Public Sub ChallengeUser (scopes As String(), Optional claims As String = Nothing, Optional userflow As String = Nothing)

参数

scopes
String[]

请求的范围。

claims
String

要确保的声明。

userflow
String

正在为 AAD B2C 调用 Userflow。

适用于