Description
We have been using Microsoft.Owin.Security.MicrosoftAccount 4.2.2 for performing Microsoft login. The Email property from external login info was used to identify the user, but it seems like it returns back unverified email, which should not be used to identify user.
According to this article we are supposed to migrate away from using email claims for user identifications, but we are unable to get any of the remediation steps listed by Microsoft to work.
Setting the authentication behavior removeUnverifiedEmailClaim to true using graph API, doesn't work and still returns unverified email.
Further it seems like we can return an optional claim xms_edov to determine verification status but we were unable to get this claim returned in the id token as well.
if we make direct requests to grab the token on the v2 authorize and token end points the added optional claims seems to be returned fine. But using the middleware those claims are not getting returned.
What is the suggested step to make sure we don't get unverified email back using Microsoft Authentication?