问题
I am using Azure AD B2C as an authentication portal. I am trying to guarantee that the Google+ always goes to select account page, by sending the query parameter prompt=select_account. But I am having an hard time reaching this behavior.
From google documentation, https://developers.google.com/identity/protocols/OpenIDConnect, it's possible to receive this parameter, which will guarantee that user goes to select account.
When following the documentation, https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-implicit-grant-flow, it seems that the prompt doesn't reach google, assuming the last authentication.
回答1:
If you want to append a static query parameter to the Auth Request that B2C makes to Google, then you need to use a Custom Policy. In which you can configure an OAuth provider for Google, and add an input claim for your query parameter.
https://docs.microsoft.com/en-us/azure/active-directory-b2c/active-directory-b2c-get-started-custom?tabs=applications
https://docs.microsoft.com/en-us/azure/active-directory-b2c/active-directory-b2c-custom-setup-goog-idp?tabs=applications
<InputClaims>
<InputClaim ClaimTypeReferenceId="QueryParamName" DefaultValue="ValueToSend"/>
</InputClaims>
来源:https://stackoverflow.com/questions/58875278/pass-parameter-to-identity-provider-on-azure-ad-b2c