SecurityTokenResolver.CreateDefaultSecurityTokenResolver 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
为指定的安全令牌创建默认安全令牌解析程序。
public:
static System::IdentityModel::Selectors::SecurityTokenResolver ^ CreateDefaultSecurityTokenResolver(System::Collections::ObjectModel::ReadOnlyCollection<System::IdentityModel::Tokens::SecurityToken ^> ^ tokens, bool canMatchLocalId);
public static System.IdentityModel.Selectors.SecurityTokenResolver CreateDefaultSecurityTokenResolver(System.Collections.ObjectModel.ReadOnlyCollection<System.IdentityModel.Tokens.SecurityToken> tokens, bool canMatchLocalId);
static member CreateDefaultSecurityTokenResolver : System.Collections.ObjectModel.ReadOnlyCollection<System.IdentityModel.Tokens.SecurityToken> * bool -> System.IdentityModel.Selectors.SecurityTokenResolver
Public Shared Function CreateDefaultSecurityTokenResolver (tokens As ReadOnlyCollection(Of SecurityToken), canMatchLocalId As Boolean) As SecurityTokenResolver
参数
- tokens
- ReadOnlyCollection<SecurityToken>
一 ReadOnlyCollection<T> 种类型 SecurityToken ,其中包含此安全令牌解析程序可以将密钥标识符和密钥标识符子句解析为的安全令牌集。
- canMatchLocalId
- Boolean
返回
解析 SecurityTokenResolver 与参数中指定的安全令牌匹配的 tokens 密钥标识符和子句。
注解
从此方法返回的安全令牌解析程序使用 MatchesKeyIdentifierClause 指定安全令牌上的和 ResolveKeyIdentifierClause 方法解析密钥标识符和密钥标识符子句。