仅具有“注册"页面的Azure AD B2C自定义策略 [英] Azure AD B2C Custom Policy with Sign Up Page Only

查看:72
本文介绍了仅具有“注册"页面的Azure AD B2C自定义策略的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在Azure AD B2C中创建自定义策略.我在starterpack中找不到这样的示例( https://github.com/Azure-Samples/active-directory-b2c-custom-policy-starterpack ).

I want to create a custom policy in Azure AD B2C. I can't find such an example in the starterpack (https://github.com/Azure-Samples/active-directory-b2c-custom-policy-starterpack).

我检查了此帖子 Azure AD B2C链接到注册页面(未登录),如果我对它的理解正确,则没有网址,我可以使用现有的自定义signup_signin策略直接在注册"页面中结束.创建注册v2"流程是可行的,但是我需要一个自定义流程,并从其中一个构建代码来处理代码,然后将其从starterpack放置到LocalAccounts示例中.

I checked this post Azure AD B2C Link to Sign Up Page (Not Sign In) and if I understand it correctly there is no url I can use of existing custom signup_signin policy to end up directly in Sign Up page. Creating "Sign up v2" flow works, but I need a custom one and coping code from the build in one and placing it to the LocalAccounts example from the starterpack doesn't work.

这是从注册v2"流程下载的UserJourney代码

This is the UserJourney code downloaded from "Sign up v2" flow

    <UserJourney Id="B2CSignUp_V2"> <OrchestrationSteps> <OrchestrationStep 
    Order="1" Type="ClaimsProviderSelection" 
    ContentDefinitionReferenceId="api.idpselections.signup"> 
    <ClaimsProviderSelections> <ClaimsProviderSelection 
    TargetClaimsExchangeId="SignUpWithLogonEmailExchange" /> 
    </ClaimsProviderSelections> </OrchestrationStep> </OrchestrationSteps> 
    </UserJourney>

我尝试将starterpack中的OrchestrationStep 1和2替换为此处的一个,但它不起作用.

I tried to replace the OrchestrationStep 1 and 2 from the starterpack with the one here but it doesn't work.

推荐答案

在您的自定义策略中,在B2C_1A_TrustFrameworkBase.xml文件中,将用户旅程Id ="SignUpOrSignIn"的第一个编排步骤替换为以下编排步骤,您将直接登陆到注册"页面-

In your Custom policies, In the B2C_1A_TrustFrameworkBase.xml file replace the 1st Orchestration Step for the User Journey Id="SignUpOrSignIn" with the following Orchestration Step and you will be directly landed to Signup page -

<OrchestrationStep Order="1" Type="ClaimsProviderSelection" ContentDefinitionReferenceId="api.idpselections.signup">
<ClaimsProviderSelections>
<ClaimsProviderSelection TargetClaimsExchangeId="SignUpWithLogonEmailExchange" />
</ClaimsProviderSelections>
</OrchestrationStep>

这篇关于仅具有“注册"页面的Azure AD B2C自定义策略的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆