Azure AD B2C always display "Please match the format requested" in email field when pressing signin

Pinel Raphaël 1 Reputation point
2021-02-06T06:26:35.697+00:00

@AmanpreetSingh-MSFT
We have created a sigin/signup using the Identity Experience Framework and custom policy in Azure AD B2C
Strangely, each time you press signin, a validation error appears "Please match the format requested" even though we enter a valid email. After that, the signin works successfully.
For the screenshot, I entered a fake email, but in real life, we enter valid emails, and the validation error still appears after pressing signin

64713-screenshot-2021-02-06-at-81611.png

Is there something we can do about it?
We are using unified 2.1.0

Microsoft Security | Microsoft Entra | Microsoft Entra External ID
{count} votes

1 answer

Sort by: Most helpful
  1. Raphaël Pinel 1 Reputation point
    2021-02-19T09:20:56.727+00:00

    After looking more into this, we fixed the issue by changing the ClaimType email and strongAuthenticationEmailAddress to use a regular Restriction-field instead of a PredicateValidation, and it seemed to fix the issue for us. Attachments included to show more precisely what we did.

    We were using email fields as in notWorking.xml. These were based on the Phone-Email-Base examples: (https://github.com/Azure-Samples/active-directory-b2c-custom-policy-starterpack/blob/master/scenarios/phone-number-passwordless/Phone_Email_Base.xml).

    We changed them to Restriction-fields as demonstrated in the Social and Local Accounts-examples (https://github.com/Azure-Samples/active-directory-b2c-custom-policy-starterpack/blob/master/SocialAndLocalAccounts/TrustFrameworkBase.xml). See attachment working.xml

    69910-notworking.xml70009-working.xml

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.