我正在尝试使用此处的示例登录Azure AD B2C应用程序:https://github.com/nordvall/TokenClient/wiki/OAuth-2-Resource-Owner-Password-Credentials-grant-in-AzureAd
配置如下:
网址:https://login.microsoftonline.com/[myapp].onmicrosoft.com/oauth2/token?api-version=1.6
传递给client_id的Azure AD B2C应用程序应用程序ID,但我实际上不确定要为该资源传递什么 . 我正在尝试为某些azure函数获取访问令牌,但是azure函数应用程序似乎没有任何特定的“资源ID”我可以在任何地方定义..
当我发布帖子请求时,我得到以下信息:
{
"error": "invalid_request",
"error_description": "AADSTS90002: Tenant not found. This may happen if there are no active subscriptions for the tenant. Check with your subscription administrator.\r\nTrace ID: x\r\nCorrelation ID: x\r\nTimestamp: 2018-02-19 10:54:20Z",
"error_codes": [
90002
],
"timestamp": "2018-02-19 10:54:20Z",
"trace_id": "x",
"correlation_id": "x"
}
1 回答
__792285_您引用的是Azure AD,而不是B2C .
Azure AD B2C当前不支持资源所有者授权流,请参阅this SO post . UserVoice request for this .
本文档可能有所帮助:Azure Active Directory B2C: Types of applications . 更具体地说:Daemons/server-side apps .