我们已经将Facebook、LinkedIn、Twitter、Google和AzureAD配置为使用自定义注册/登录策略的提供商。
当用户使用社交Idp(Facebook、LinkedIn、Twitter、Google)注册时,我们有一个要求商业邮件的要求,而不是当Azure选择时(因为他们已经在使用他们的商业电子邮件)。
我在本节中添加了新的属性,
<TechnicalProfile Id="SelfAsserted-Social">请建议一下。
发布于 2018-04-04 11:05:49
首先,您必须确定企业帐户或社会帐户是否已登录。
例如:
<TechnicalProfile Id="ContosoProfile">
<OutputClaims>
<OutputClaim ClaimTypeReferenceId="authenticationSource" DefaultValue="contosoAuthentication" />
</OutputClaims>
</TechnicalProfile>以及:
<TechnicalProfile Id="Facebook-OAUTH">
<OutputClaims>
<OutputClaim ClaimTypeReferenceId="authenticationSource" DefaultValue="socialIdpAuthentication" />
</OutputClaims>
</TechnicalProfile>其次,您必须为帐户注册创建两个技术概要:一个用于企业帐户注册的技术概要(不包括商业电子邮件)和另一个用于包括它的社会帐户注册的技术配置文件。
例如:
<ClaimsProvider>
<DisplayName>Self Asserted</DisplayName>
<TechnicalProfiles>
<TechnicalProfile Id="SelfAsserted-Enterprise">
...
</TechnicalProfile>
<TechnicalProfile Id="SelfAsserted-Social">
...
</TechnicalProfile>
</TechnicalProfiles>
</ClaimsProvider>第三,基于authenticationSource声明,您必须调用一个或另一个技术概要。
例如:
<UserJourney Id="SignUpOrSignIn">
<OrchestrationSteps>
<OrchestrationStep Order="4" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimsExist" ExecuteActionsIf="true">
<Value>objectId</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>socialIdpAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="SelfAsserted-Enterprise" TechnicalProfileReferenceId="SelfAsserted-Enterprise" />
</ClaimsExchanges>
</OrchestrationStep>
<OrchestrationStep Order="5" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimsExist" ExecuteActionsIf="true">
<Value>objectId</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>contosoAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="SelfAsserted-Social" TechnicalProfileReferenceId="SelfAsserted-Social" />
</ClaimsExchanges>
</OrchestrationStep>
</OrchestrationSteps>
</UserJourney>https://stackoverflow.com/questions/49635449
复制相似问题