语言

Saml2SecurityTokenHandler.SetDelegateFromAttribute 方法

定义

检测到特殊类型的 Saml2Attribute 方法时,将调用此方法。 Saml2Attribute传入的包装一个Saml2Attribute包含属性值集合(在Values属性中),每个属性都将映射到声明。 所有声明都将在具有指定颁发者的一个 ClaimsIdentity 中返回。

protected:
 virtual void SetDelegateFromAttribute(System::IdentityModel::Tokens::Saml2Attribute ^ attribute, System::Security::Claims::ClaimsIdentity ^ subject, System::String ^ issuer);
protected virtual void SetDelegateFromAttribute(System.IdentityModel.Tokens.Saml2Attribute attribute, System.Security.Claims.ClaimsIdentity subject, string issuer);
abstract member SetDelegateFromAttribute : System.IdentityModel.Tokens.Saml2Attribute * System.Security.Claims.ClaimsIdentity * string -> unit
override this.SetDelegateFromAttribute : System.IdentityModel.Tokens.Saml2Attribute * System.Security.Claims.ClaimsIdentity * string -> unit
Protected Overridable Sub SetDelegateFromAttribute (attribute As Saml2Attribute, subject As ClaimsIdentity, issuer As String)

参数

attribute
Saml2Attribute

要使用的 Saml2Attribute 。

subject
ClaimsIdentity

这是 ClaimsIdentity 此令牌的主题。

issuer
String

声明的颁发者。

例外

不包含 Saml2Attribute 任何有效的属性值。

适用于