- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我尝试在首次登录(在 Azure ADB2C 中)后使用自定义策略强制重置密码,如 the "reset password" repo 中所述。 .
我正在使用自定义策略,并且在尝试上传“SignUpOrSignin.xml”自定义策略时出现验证错误。消息是:
A required Metadata item with key "ApplicationObjectId" was not foundin the TechnicalProfile with id"AAD-UserRemoveMustResetPasswordUsingObjectId" in policy"B2C_1A_signup_signin" of tenant "resetpasswordtest.onmicrosoft.com"
这些是我遵循的步骤:
TrustFrameworkBase.xml
TrustFrameworkExtensions.xml
PasswordReset.xml
ProfileEdit.xml
SignUpOrSignin.xml
当我尝试上传最后一个 (SignUpOrSignin.xml) 时出现问题这里有什么问题吗? Here您可以找到前面 5 个 xml 文件的完整实现。
请查看以下部分,我在其中粘贴了“TrustFrameworkExtensions.xml”和“SignUpOrSignin.xml”自定义策略。
感谢您的阅读
<TrustFrameworkPolicy
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://schemas.microsoft.com/online/cpim/schemas/2013/06"
PolicySchemaVersion="0.3.0.0"
TenantId="resetpasswordtest.onmicrosoft.com"
PolicyId="B2C_1A_TrustFrameworkExtensions"
PublicPolicyUri="http://resetpasswordtest.onmicrosoft.com/B2C_1A_TrustFrameworkExtensions">
<BasePolicy>
<TenantId>resetpasswordtest.onmicrosoft.com</TenantId>
<PolicyId>B2C_1A_TrustFrameworkBase</PolicyId>
</BasePolicy>
<BuildingBlocks>
<ClaimsSchema>
<!--Demo: Specifies whether user must reset the password-->
<ClaimType Id="extension_mustResetPassword">
<DisplayName>Must reset password</DisplayName>
<DataType>boolean</DataType>
<UserHelpText>Specifies whether user must reset the password</UserHelpText>
</ClaimType>
</ClaimsSchema>
</BuildingBlocks>
<ClaimsProviders>
<ClaimsProvider>
<DisplayName>Azure Active Directory</DisplayName>
<TechnicalProfiles>
<TechnicalProfile Id="AAD-UserReadUsingObjectId">
<OutputClaims>
<!--Demo: Read the 'must reset password' extension attribute -->
<OutputClaim ClaimTypeReferenceId="extension_mustResetPassword" />
</OutputClaims>
</TechnicalProfile>
<TechnicalProfile Id="AAD-UserRemoveMustResetPasswordUsingObjectId">
<Metadata>
<Item Key="Operation">DeleteClaims</Item>
</Metadata>
<InputClaims>
<InputClaim ClaimTypeReferenceId="objectId" Required="true" />
</InputClaims>
<PersistedClaims>
<PersistedClaim ClaimTypeReferenceId="objectId" />
<PersistedClaim ClaimTypeReferenceId="extension_mustResetPassword" />
</PersistedClaims>
<IncludeTechnicalProfile ReferenceId="AAD-Common" />
</TechnicalProfile>
<!--Demo: to create the extension attribute extension_mustResetPassword, you should upload the policy
and create one account. Then ***comment out this technical profile***.
-->
<TechnicalProfile Id="AAD-UserWriteUsingLogonEmail">
<PersistedClaims>
<PersistedClaim ClaimTypeReferenceId="extension_mustResetPassword" DefaultValue="true" />
</PersistedClaims>
</TechnicalProfile>
</TechnicalProfiles>
</ClaimsProvider>
<!-- Facebook claims provider -->
<ClaimsProvider>
<DisplayName>Facebook</DisplayName>
<TechnicalProfiles>
<TechnicalProfile Id="Facebook-OAUTH">
<Metadata>
<!--Demo action required: Change to your Facebook App Id-->
<Item Key="client_id">313412440187068</Item>
<Item Key="scope">email public_profile</Item>
<Item Key="ClaimsEndpoint">https://graph.facebook.com/me?fields=id,first_name,last_name,name,email</Item>
</Metadata>
</TechnicalProfile>
</TechnicalProfiles>
</ClaimsProvider>
<ClaimsProvider>
<DisplayName>Local Account SignIn</DisplayName>
<TechnicalProfiles>
<TechnicalProfile Id="login-NonInteractive">
<Metadata>
<Item Key="client_id">44444444-2222-2222-2222-555555555555</Item>
<Item Key="IdTokenAudience">44444444-2222-2222-2222-555555555555</Item>
</Metadata>
<InputClaims>
<InputClaim ClaimTypeReferenceId="client_id" DefaultValue="44444444-2222-2222-2222-555555555555" />
<InputClaim ClaimTypeReferenceId="resource_id" PartnerClaimType="resource" DefaultValue="44444444-2222-2222-2222-555555555555" />
</InputClaims>
</TechnicalProfile>
</TechnicalProfiles>
</ClaimsProvider>
</ClaimsProviders>
<UserJourneys>
<UserJourney Id="SignUpOrSignInWithForcePasswordReset">
<OrchestrationSteps>
<OrchestrationStep Order="1" Type="CombinedSignInAndSignUp" ContentDefinitionReferenceId="api.signuporsignin">
<ClaimsProviderSelections>
<ClaimsProviderSelection TargetClaimsExchangeId="FacebookExchange" />
<ClaimsProviderSelection ValidationClaimsExchangeId="LocalAccountSigninEmailExchange" />
</ClaimsProviderSelections>
<ClaimsExchanges>
<ClaimsExchange Id="LocalAccountSigninEmailExchange" TechnicalProfileReferenceId="SelfAsserted-LocalAccountSignin-Email" />
</ClaimsExchanges>
</OrchestrationStep>
<!-- Check if the user has selected to sign in using one of the social providers -->
<OrchestrationStep Order="2" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimsExist" ExecuteActionsIf="true">
<Value>objectId</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="FacebookExchange" TechnicalProfileReferenceId="Facebook-OAUTH" />
<ClaimsExchange Id="SignUpWithLogonEmailExchange" TechnicalProfileReferenceId="LocalAccountSignUpWithLogonEmail" />
</ClaimsExchanges>
</OrchestrationStep>
<!-- For social IDP authentication, attempt to find the user account in the directory. -->
<OrchestrationStep Order="3" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>localAccountAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="AADUserReadUsingAlternativeSecurityId" TechnicalProfileReferenceId="AAD-UserReadUsingAlternativeSecurityId-NoError" />
</ClaimsExchanges>
</OrchestrationStep>
<!-- Show self-asserted page only if the directory does not have the user account already (i.e. we do not have an objectId).
This can only happen when authentication happened using a social IDP. If local account was created or authentication done
using ESTS in step 2, then an user account must exist in the directory by this time. -->
<OrchestrationStep Order="4" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimsExist" ExecuteActionsIf="true">
<Value>objectId</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="SelfAsserted-Social" TechnicalProfileReferenceId="SelfAsserted-Social" />
</ClaimsExchanges>
</OrchestrationStep>
<!-- This step reads any user attributes that we may not have received when authenticating using ESTS so they can be sent
in the token. -->
<OrchestrationStep Order="5" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>socialIdpAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="AADUserReadWithObjectId" TechnicalProfileReferenceId="AAD-UserReadUsingObjectId" />
</ClaimsExchanges>
</OrchestrationStep>
<!--Demo: check if change password is required. If yes, ask the user to reset the password-->
<OrchestrationStep Order="6" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>socialIdpAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimsExist" ExecuteActionsIf="false">
<Value>extension_mustResetPassword</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimEquals" ExecuteActionsIf="false">
<Value>extension_mustResetPassword</Value>
<Value>True</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="NewCredentials" TechnicalProfileReferenceId="LocalAccountWritePasswordUsingObjectId" />
</ClaimsExchanges>
</OrchestrationStep>
<!--Demo: check if change password is required. If yes remove the value of the extension attribute.
So, on the next time user dons' t need to update the password-->
<OrchestrationStep Order="7" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimEquals" ExecuteActionsIf="true">
<Value>authenticationSource</Value>
<Value>socialIdpAuthentication</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimsExist" ExecuteActionsIf="false">
<Value>extension_mustResetPassword</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
<Precondition Type="ClaimEquals" ExecuteActionsIf="false">
<Value>extension_mustResetPassword</Value>
<Value>True</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="AADUserRemoveMustResetPasswordUsingObjectId" TechnicalProfileReferenceId="AAD-UserRemoveMustResetPasswordUsingObjectId" />
</ClaimsExchanges>
</OrchestrationStep>
<!-- The previous step (SelfAsserted-Social) could have been skipped if there were no attributes to collect
from the user. So, in that case, create the user in the directory if one does not already exist
(verified using objectId which would be set from the last step if account was created in the directory. -->
<OrchestrationStep Order="8" Type="ClaimsExchange">
<Preconditions>
<Precondition Type="ClaimsExist" ExecuteActionsIf="true">
<Value>objectId</Value>
<Action>SkipThisOrchestrationStep</Action>
</Precondition>
</Preconditions>
<ClaimsExchanges>
<ClaimsExchange Id="AADUserWrite" TechnicalProfileReferenceId="AAD-UserWriteUsingAlternativeSecurityId" />
</ClaimsExchanges>
</OrchestrationStep>
<OrchestrationStep Order="9" Type="SendClaims" CpimIssuerTechnicalProfileReferenceId="JwtIssuer" />
</OrchestrationSteps>
<ClientDefinition ReferenceId="DefaultWeb" />
</UserJourney>
</UserJourneys>
</TrustFrameworkPolicy>
<TrustFrameworkPolicy
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://schemas.microsoft.com/online/cpim/schemas/2013/06"
PolicySchemaVersion="0.3.0.0"
TenantId="resetpasswordtest.onmicrosoft.com"
PolicyId="B2C_1A_signup_signin"
PublicPolicyUri="http://resetpasswordtest.onmicrosoft.com/B2C_1A_signup_signin">
<BasePolicy>
<TenantId>resetpasswordtest.onmicrosoft.com</TenantId>
<PolicyId>B2C_1A_TrustFrameworkExtensions</PolicyId>
</BasePolicy>
<RelyingParty>
<DefaultUserJourney ReferenceId="SignUpOrSignInWithForcePasswordReset" />
<TechnicalProfile Id="PolicyProfile">
<DisplayName>PolicyProfile</DisplayName>
<Protocol Name="OpenIdConnect" />
<OutputClaims>
<OutputClaim ClaimTypeReferenceId="displayName" />
<OutputClaim ClaimTypeReferenceId="givenName" />
<OutputClaim ClaimTypeReferenceId="surname" />
<OutputClaim ClaimTypeReferenceId="email" />
<OutputClaim ClaimTypeReferenceId="objectId" PartnerClaimType="sub"/>
<OutputClaim ClaimTypeReferenceId="identityProvider" />
<OutputClaim ClaimTypeReferenceId="tenantId" AlwaysUseDefaultValue="true" DefaultValue="{Policy:TenantObjectId}" />
</OutputClaims>
<SubjectNamingInfo ClaimType="sub" />
</TechnicalProfile>
</RelyingParty>
</TrustFrameworkPolicy>
最佳答案
您错过了配置扩展属性支持的策略。 https://learn.microsoft.com/en-us/azure/active-directory-b2c/user-flow-custom-attributes?pivots=b2c-custom-policy#azure-ad-b2c-extensions-app
整个过程可以使用我的工具自动化:https://aka.ms/iefsetup在开始使用示例之前。
关于首次登录时重置密码期间出现 Azure AD B2C 错误(使用自定义策略),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/67678365/
我有一个场景,我们必须通过 Azure AD 对企业用户进行身份验证,但通过 Azure AD B2C 对外部用户进行身份验证——所有这些都来自同一个登录屏幕。 有一些 Web 应用程序将共享此功能。
在使用 Azure AD B2C 和 Azure AD B2B 之前,我通常会将应用程序添加到我们租户的 Azure AD 中,并且 Office 365 用户可以使用其帐户 (SSO) 访问应用程序
当 Azure Active Directory 信任访问本地 Active Directory 用户时,我们是否可以使用本地 AD 用户名(域限定的 sam 帐户名称,例如:cosmos\brahm
什么是在网站上展示广告的好托管广告管理器? 我听说过OpenX ,但从未使用过。 最佳答案 我们使用名为 Ad Serving Solutions http://www.adservingsoluti
是否可以将用户从云 Azure Active Directory 同步到本地 AD? On Premises 这里有点错误,因为它实际上是 Azure 中的虚拟网络,带有 Windows Server
我正在关注这里的答案:Multi-Tenant Azure AD Auth in Azure AD B2C with Custom Policies 以及这里的演练:https://github.co
我正在尝试使用/common Azure AD 端点在 Azure AD B2C 中使用 Azure AD Auth。根据How to sign in any Azure Active Directo
来自 Mercurial 文档: The manifest is the file that describes the contents of the repository at a particu
我正在尝试将 firebase admob 与 React Native 集成到我的应用程序中,一切都适用于 testID横幅 ('ca-app-pub-3940256099942544/293473
我有一个应用程序需要根据其本地 AD 通用名称来过滤权限。几点注意事项: Azure AD Connect 正在 OnPrem AD 和 Azure 之间同步数据 我已成功将登录用户的组信息从 Azu
我正在使用 blogspot 平台并在我的网站上使用了 Google Adsense。我想对齐一个自动 Adsense 广告,它根本不居中,而带有代码的广告则完全没有问题。它只是自动广告,有人可以帮助
为什么redirect URL必须完全匹配?在域级别进行匹配是否不足以提供适当的安全性? 如果我有数百条路径怎么办? 示例网址: https://myawesomesite.com https://m
我即将创建一个新的 Azure AKS 群集,并且希望将 AKS 与 Azure Key Vault 集成。几个月前,在学习阶段,我看到需要使用Azure AD pod管理的身份来做到这一点,但现在我
我正在尝试配置我的 Azure AD 以同步我的本地 AD DS,如果在 Microsoft Azure AD 中添加任何用户,它应该自动在我的本地 AD 中注册。 我已创建 Azure AD 并配置
我有大约 50 个用户的 Azure AD。这些用户是我们购买Office365时创建的。假设 Azure AD 上的域是 example.com。 ([email protected])在本地,我们
我正在尝试获取组 Azure AD 的名称,Azure 登录 (openId) 后的内部 token 我收到 json 格式的组 ID,但我需要组名称。 登录后的Json: Claims 尝试使用Gr
我们希望将 Azure AD B2C 用于我们的 Web 应用程序,以允许用户使用其公司 ADFS 帐户登录。 根据Azure Active Directory B2C: Add ADFS as a
首先,我无法了解为什么需要这些数据,也无法了解有关网络的细节。您必须相信我,除了运行 LDAP 查询的 PowerShell 脚本之外,没有其他方法可以获取这些数据。 我正在使用具有多个林和多个域的网
我是一个相当新的 PS 用户...正在寻求有关 powershell 脚本的帮助来获取用户所属的安全组列表。 描述我需要什么: 我有包含许多用户(samaccountnames)的输入列表(txt 文
我有两个要存储在目录中以供我的应用程序使用的声明。这些内容不可供用户编辑,但可用于应用程序从 token 中读取。 内置策略可以检索声明,但是,使用自定义策略检索这些声明没有取得任何成功。 通读文章“
我是一名优秀的程序员,十分优秀!