BaseAuthRequest type

BaseAuthRequest

  • authority - 颁发机构 URL、MSAL 将从中获取令牌的安全令牌服务(STS)。 默认值为 https://login.microsoftonline.com/common. 如果对所有请求使用相同的颁发机构,则应在客户端应用程序对象上设置颁发机构,而不是请求,以避免多次解析颁发机构终结点。
  • correlationId - 每个请求的唯一 GUID 集,用于跟踪用于遥测目的的请求端到端。
  • scopes - 应用程序请求访问的范围数组。
  • authenticationScheme - 检索的令牌类型。 默认为“Bearer”。 也可以键入“pop”或“SSH”。
  • claims - 字符串化的声明请求,请求将添加到所有 /authorize 和 /token 调用
  • shrClaims - 将添加到已签名 HTTP 请求的字符串化声明对象
  • shrNonce - 已加密和 base64URL 编码的服务器生成的时间戳,该时间戳将添加到已签名的 HTTP 请求中。
  • shrOptions - 包含已签名 HTTP 请求选项的对象
  • resourceRequestMethod - 用于从资源请求数据的 HTTP 请求类型(例如“GET”、“POST”等)。 用于所有权证明流。
  • resourceRequestUri - 令牌将用于的 URI。 用于所有权证明流。
  • sshJwk - 一个字符串化的 JSON Web 密钥,表示可由 SSH 证书签名的公钥。
  • sshKid - 唯一标识上面提到的 SSH 公钥的密钥 ID。
  • azureCloudOptions - 方便用户提供公共/主权云 ID 的便利字符串枚举
  • requestedClaimsHash - 所请求声明字符串的 SHA 256 哈希字符串,用作访问令牌缓存密钥的一部分,以便令牌可由请求的声明进行筛选
  • tokenQueryParameters - 添加到 /token 调用的自定义查询参数的字符串映射
  • tokenBodyParameters - 添加到 /token 调用正文的自定义参数的字符串到字符串映射
  • storeInCache - 包含布尔值的对象,指示是否在缓存中存储令牌(默认值为 true)
  • scenarioId - 用于跟踪自定义用户提示的方案 ID
  • popKid - 用于标识 PoP 令牌请求公钥的密钥 ID
  • embeddedClientId - Embedded 客户端 ID。指定后,代理客户端 ID (brk_client_id) 和重定向 URI (brk_redirect_uri) 参数使用配置中的值进行设置,如果存在,则重写相应的额外参数。
  • httpMethod - 用于 /authorize 请求的 HTTP 方法。 默认值为 GET,但如果请求需要正文参数,则可以设置为 POST
  • authorizePostBodyParameters - 当 httpMethod 设置为 POST 时添加到 /authorize 调用正文的自定义参数的字符串映射
  • skipBrokerClaims - 如果使用 true 和中转流(例如,如果存在中转站参数或 embeddedClientId),则从配置中排除 clientCapabilities;对于非中转流,忽略。
type BaseAuthRequest = {
  authenticationScheme?: AuthenticationScheme
  authority: string
  authorizePostBodyParameters?: StringDict
  azureCloudOptions?: AzureCloudOptions
  claims?: string
  correlationId: string
  embeddedClientId?: string
  httpMethod?: HttpMethod
  maxAge?: number
  popKid?: string
  requestedClaimsHash?: string
  resourceRequestMethod?: string
  resourceRequestUri?: string
  scenarioId?: string
  scopes: string[]
  shrClaims?: string
  shrNonce?: string
  shrOptions?: ShrOptions
  skipBrokerClaims?: boolean
  sshJwk?: string
  sshKid?: string
  storeInCache?: StoreInCache
  tokenBodyParameters?: StringDict
  tokenQueryParameters?: StringDict
}