Add restricted claim UPN to saml

Ritu Raj 161 Reputation points
2021-04-10T18:22:22.677+00:00

I am trying to setup SSO with an app via saml. The app expects upn in the claim but sadly upn attribute is not being passed in the claim.
Since upn is a restricted attribute I can not add it to the custom attribute way . Adding it as an optional attribute via Manifest is also not working.

Is it possible to pass upn attribute at all via the saml token?

Microsoft Security | Microsoft Entra | Microsoft Entra ID
0 comments No comments

3 answers

Sort by: Newest
  1. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.

    1 deleted comment

    Comments have been turned off. Learn more

  2. Ritu Raj 161 Reputation points
    2021-04-12T10:15:37.653+00:00

    Hi @sikumars-msft ,

    This is not with the namespace that the upn should have. The configured application does not identfy as a valid upn. This should have a valid namespace like the ones :
    http://schemas.xmlsoap.org/ws/2005/05/identity/claims/upn

    Do you have any trick for that.

    Was this answer helpful?

    0 comments No comments

  3. Siva-kumar-selvaraj 15,441 Reputation points Volunteer Moderator
    2021-04-12T08:22:52.42+00:00

    Hello @Ritu Raj ,

    Thanks for reaching out.

    Could you please try adding "new claim" set from "User Attributes & Claims" section from Azure AD Enterprise Application as shown below:

    Steps:
    1.Under User Attributes & Claims, click the edit symbol
    86808-image.png

    2.Click Add new claim
    86810-image.png

    3.Write displayname in the Name field
    4.Leave Namespace as empty
    5.Choose Attribute as Source
    6.Select user.userprincipalname as Source attribute and Save it.

    86861-image.png

    Here is an example of UPN claim in SAML token. Hope this helps.

    86768-image.png

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

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

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.