Skip to content

Latest commit

 

History

History
 
 

pwd-reset-via-email-or-phone

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Password Reset - Via either Email or Phone verification

Demonstrate how to use a displayControl to conditionally process on the users decision to verify their account via Email OTP or SMS.

Prerequisites

  • You can automate the pre requisites by visiting this site if you already have an Azure AD B2C tenant. Some policies can be deployed directly through this app via the Experimental menu.

  • You will require to create an Azure AD B2C directory, see the guidance here.

  • To use the sample policies in this repo, follow the instructions here to setup your AAD B2C environment for Custom Policies here.

  • For any custom policy sample which makes use of Extension attributes, follow the guidance here and here. The AAD-Common Technical profile will always need to be modified to use your ApplicationId and ObjectId.

How it works

  1. Read the users profile once they provide their email address. This will provide their phone number used to Sign Up.
  2. Use a displayControl to display the user a radio box selection on whether to verify their account via Email or Phone.
  3. The displayControl uses preconditions on the SendCode and VerifyCode actions to control the ValidationClaimsExchangeTechnicalProfile based on the users selection on whether to use phone or email to verify their account. That decision is held in the claim mfaType, which acts as the radio box.

Community Help and Support

Use Stack Overflow to get support from the community. Ask your questions on Stack Overflow first and browse existing issues to see if someone has asked your question before. Make sure that your questions or comments are tagged with [azure-ad-b2c]. If you find a bug in the sample, please raise the issue on GitHub Issues. To provide product feedback, visit the Azure Active Directory B2C Feedback page.

Notes

This sample policy is based on SocialAndLocalAccountsWithMFA starter pack. All changes are marked with Sample: comment inside the policy XML files. Make the necessary changes in the Sample action required sections.