Azure-Samples / active-directory-b2c-custom-policy-starterpack

Azure AD B2C now allows uploading of a Custom Policy which allows full control and customization of the Identity Experience Framework
http://aka.ms/aadb2ccustom
MIT License
340 stars 394 forks source link

Standard Email Sign up page for Social Media #94

Closed 1992-rd closed 2 years ago

1992-rd commented 3 years ago

Is it possible to set Social account Sign-up and sign in page separately through ADB2C Custom policy, can it be initiated along with standard email sign-up page?

Please find below sample policy we have used for Social media.

https://github.com/azure-ad-b2c/samples/tree/master/policies/idps-filter/policy

JasSuri commented 3 years ago

There is no way to do this without HTML customization.

First place Social Media buttons on the Sign Up page HTML. Link each button back to the application, with a domain_hint. Eg: the Facebook button will point to https://myapp.com/signin?domain_hint=facebook. Use MSAL library in your app to use the extraQueryParameters array to pass the domain_hint to AAD B2C, and this will force the user to Sign In or Up with Facebook.

Now the user has ability to sign up with Facebook from a UX perspective, from a B2C perspective, its always a Sign In, and we just-in-time do Sign Up if its their first social login.

yoelhor commented 2 years ago

Closing due to inactivity