ExternalLogin Azure B2C email claim in Umbraco 9

Hi there,

I’m trying to migrate from Umbraco 8.x to 9.0.1. All works fine, except the external backoffice authentication (Azure B2C). In this case I want to login using Azure AD B2C (which currencly has local accounts, and Azure AD. In the future there will be more options).

The old implementation of the external login was quite different (based on Integrating Umbraco 8 with Azure Active Directory B2C)

I try to simplify this implementation by using the build in external login providers (external-login-providers - security - reference - Documentation - our.umbraco.com).

My current setup let me authenticate against Azure AD B2C. The login works fine. The one thing is that after a succesful login, Umbraco says the email claim is missing:

The implementation I used came from auto-linking - security - reference - Documentation - our.umbraco.com

I tried to hook into OnAutoLinking and OnExternalLogin, but this seems not to be called yet (auto-linking - security - reference - Documentation - our.umbraco.com).

When I take a look at the claims that are returned, I do have an ‘emails’ claim. I do not have the ‘email’ claim. I would like to use the value from ‘emails’ for linking the accounts.

How can I get this account linking to work?


This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/107424-externallogin-azure-b2c-email-claim-in-umbraco-9