Azure b2c Custom Policies Error Message

Miguel Gregório 21 Reputation points
2020-11-28T23:47:43.567+00:00

Hi !

I programmed the b2c customized policies and I am currently defining the error messages. However, the login error message displays a message that does not count in the standard messages: https://learn.microsoft.com/en-us/azure/active-directory-b2c/localization-string-ids

The message is: The username or password provided in the request are invalid.

I used the strarter pack policies (local account).
If the credentials are correct, no problems arises.

how can i change this message?

Thanks!!
43483-capture.png

Microsoft Entra External ID
Microsoft Entra External ID
A modern identity solution for securing access to customer, citizen and partner-facing apps and services. It is the converged platform of Azure AD External Identities B2B and B2C. Replaces Azure Active Directory External Identities.
2,634 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,436 questions
{count} votes

Accepted answer
  1. AmanpreetSingh-MSFT 56,306 Reputation points
    2020-11-30T14:55:10.203+00:00

    Hi @Miguel Gregório · Thank you for sharing the required information.

    By investigating into it, I found the error occurs only when the policy is configured with ROPC flow. There is an open ticket regarding this issue with the product team.

    As of now, you can try removing <Item Key="grant_type">password</Item> from <TechnicalProfile Id="login-NonInteractive">. As long as, the first OrchestrationStep in an ROPC user journey is the ClaimsExchange with the ROPC technical profile, it should be absolutely fine to remove it.

    -----------------------------------------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.

    1 person found this answer helpful.

6 additional answers

Sort by: Most helpful
  1. Michał Dzierżak 1 Reputation point
    2021-01-18T18:17:31.453+00:00

    Hi :-)
    Any news on the above problem?
    We have facing the same issue. Message The username or password provided in the request are invalid. cannot be translated by custom policy. After some investigation I've found that it is returned as an exception during executing login-NonInteractive profile:

    {
        "Key": "Exception",
        "Value": {
            "Kind": "Handled",
            "HResult": "80131500",
            "Message": "The username or password provided in the request are invalid.",
            "Data": {
            "IsPolicySpecificError": false
            }
        }
    }
    

    Regards,
    Michał


  2. VipulSparsh-MSFT 16,231 Reputation points Microsoft Employee
    2021-02-17T13:52:31.227+00:00
    0 comments No comments