I have a site with Single sign on through an Azure AD on the same Azure platform. It works fine when logging in as a user from AD, but if I’m logged in on my Hotmail with my windows account and tries to log in on my site, then my site will try to log me in with my windows account, and it gives the following error:
Correlation ID: 8b6b1487-6acf-45bb-90e3-2b790f4edf40
Timestamp: 2015-09-16 20:48:43Z
AADSTS50020: User account 'xxx@phmetropol.dk' from external identity provider 'https://sts.windows.net/a522aa78-7419-49dc-ab5b-d757f96c8883/' is not supported for application 'https://bygdrift.onmicrosoft.com/'. The account needs to be added as an external user in the tenant. Please sign out and sign in again with an Azure Active Directory user account.
My issue is, that I can’t help a user that gets stuck on this error page. There are no buttons the user can click to get back to my site or a redirect automation.
The site that I am testing it with, is a pure example from github:github.com/AzureADSamples/WebApp-OpenIDConnect-DotNet
Can I do anything to redirect the user away from the errorpage?