具有自定义策略的Azure AD B2C:无法使用临时密码对用户进行身份验证

And*_*ard 6 azure-ad-b2c

我已使用自定义策略配置Azure AD B2C,但我无法使用Azure门户中创建的新用户进行身份验证.用户有一个临时密码.即使用户名和密码正确,Azure AD B2C 也会返回错误文本无效的用户名或密码.

我已确认可以使用非自定义策略在Azure AD B2C中使用新用户和临时密码登录.登录后,系统会提示用户更改其密码.

可以使用本指南中描述的自定义策略重现该问题: 开始使用自定义策略.

附加信息:

我在UserJourneyRecorderEndpoint https://b2crecorder.azurewebsites.net/stream?id=<guid>中配置了b2crecorder.通过它可以访问更多信息https://b2crecorder.azurewebsites.net/trace_102.html?id=<guid>

该问题导致以下日志记录:

SelfAssertedMessageValidationHandler

The message was received from null

Validation via SelfAssertedAttributeProvider

Additional validation is required...

OperativeTechnicalProfile is login-NonInteractive

Mapping 'username' partner claim type to 'signInName' policy claim type

Mapping default value 'undefined' to policy 'grant_type'

Mapping default value 'undefined' to policy 'scope'

Mapping default value 'undefined' to policy 'nca'

Mapping default value 'undefined' to policy 'client_id'

Mapping default value 'undefined' to policy 'resource_id'

Using validation endpoint at: https://login.microsoftonline.com/xxxx.onmicrosoft.com/oauth2/token

Orchestration Step: 1

RA: 0

Protocol selected by the caller: OAUTH2

Communications with the caller handled by: OAuth2ProtocolProvider

IC: True

OAuth2 Message: MSG(d56987e9-be2e-46fc-a7a4-23e317f8f174) Message Detail

ValidationRequest:

ValidationResponse:

Exception:

Exception of type 'Web.TPEngine.Providers.BadArgumentRetryNeededException' was thrown.
Run Code Online (Sandbox Code Playgroud)

Sae*_*ter 11

最常见的原因是Grant Permissions尚未执行.

在"ProxyIdentityExperienceFramework应用程序" - >选中Access IdentityExperienceFramework的复选框 - >单击选择并点击完成后,您还必须完成下一步:

选择" 授予权限",然后选择" 是"进行确认.

编辑:

很抱歉,在仔细阅读您的情况后,"注册或登录策略"或"自定义策略"都不支持Azure Active Directory forceChangePasswordNextLogin标记.(forceChangePasswordNextLogin仅适用于"注册政策")此处有跟踪此功能的功能请求.