Azure AD B2C Error: The client Id specified in the request is not registered in tenant

后端 未结 3 1091
野性不改
野性不改 2021-01-13 16:39

I am attempting to log in to an Azure Active Directory B2C application.

Whenever I access the URL https://login.microsoftonline.com/te//

相关标签:
3条回答
  • 2021-01-13 17:02

    All you need to do is to grant admin consent for the Organization registered in the API Permission menu under the manage app setting. It worked for me immediately

    0 讨论(0)
  • I think the reason for this is that the API Permissions aren't pre-provisioned when you create an app through the AD blade (or Graph API). The way to resolve is to add the API Permissions to the app:

    Having just gone through the process of automating this I can tell you that there are four layers that have to be configured for this to work using Graph API (Note: using the beta endpoints).

    1. Create application https://docs.microsoft.com/en-us/graph/api/application-post-applications?view=graph-rest-beta&tabs=http

    2. Update application properties https://docs.microsoft.com/en-us/graph/api/application-update?view=graph-rest-beta&tabs=http a. requiredResourceAccess https://docs.microsoft.com/en-us/graph/api/resources/requiredresourceaccess?view=graph-rest-beta b. Any other properties, like implicitGrantSettings, logoutUrl, etc

    3. Create Service Principal for app just created: https://docs.microsoft.com/en-us/graph/api/serviceprincipal-post-serviceprincipals?view=graph-rest-beta&tabs=http

    4. Create oauth2PermissionGrants using the object id of the service principal: https://docs.microsoft.com/en-us/graph/api/oauth2permissiongrant-post?view=graph-rest-beta&tabs=http

    0 讨论(0)
  • 2021-01-13 17:18

    The https://login.microsoftonline.com/te/<tenant_id>/<policy_id>/oauth2/v2.0/authorize?client_id=<client_id>... URL is correct, but you shouldn't create an Azure AD B2C application using the Application Registration Portal, otherwise it becomes a faulted app and you then receive the The client id ... specified in the request is not registered in tenant ... error.

    An Azure AD B2C application should be created using the Azure AD B2C blade of the Azure Portal.

    0 讨论(0)
提交回复
热议问题