你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

AppServiceTokenHandler 类

定义

提供 IAppServiceTokenHandler 接口的默认实现。

public class AppServiceTokenHandler : Microsoft.Azure.Mobile.Server.Authentication.IAppServiceTokenHandler
type AppServiceTokenHandler = class
    interface IAppServiceTokenHandler
Public Class AppServiceTokenHandler
Implements IAppServiceTokenHandler
继承
AppServiceTokenHandler
实现

构造函数

AppServiceTokenHandler(HttpConfiguration)

初始化 AppServiceTokenHandler 类的新实例。

方法

CreateUserId(String, String)

创建包含在 中的 ProviderCredentials用户 ID 值。 用户 ID 采用的形式 ProviderName:ProviderId ,其中 ProviderName 是登录提供程序的唯一标识符, ProviderId 而 是给定用户的提供程序特定 ID。

TryParseUserId(String, String, String)

将用户 ID 分析为其两个组件:一个唯一 ProviderName 标识登录提供程序,一 ProviderId 个标识给定用户的提供程序特定 ID。

TryValidateLoginToken(String, String, IEnumerable<String>, IEnumerable<String>, ClaimsPrincipal)

验证用于对用户请求进行身份验证的移动服务身份验证令牌的字符串表示形式。

TryValidateToken(TokenValidationParameters, String, String, ClaimsPrincipal)

提供 IAppServiceTokenHandler 接口的默认实现。

ValidateToken(String, String, String, String)

针对指定的密钥验证指定的 JWT 令牌字符串。 不会捕获验证方法引发的异常。

适用于