Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Ruder Partap Singh 28 posts 142 karma points
    Feb 12, 2022 @ 19:41
    Ruder Partap Singh
    0

    how to add custom claim to the loggedin member in umbraco 9

    Hi

    I am trying to add custom claim to the logged-in member in umbraco 9.2. I am authenticating user using AD B2C (followed https://www.scottbrady91.com/umbraco/frontend-members-sso-openid-connect tutorial) and successfully able to login. now i want to add custom claim to the logged in member. is there any way to add custom claim to the member

    Thanks

  • Ruder Partap Singh 28 posts 142 karma points
    Mar 19, 2022 @ 07:48
  • Elbert Price 1 post 71 karma points
    Mar 21, 2022 @ 12:18
    Elbert Price
    0

    He problem is the default B2C integration doesn't return the email claim, which is needed for autolink. I do not want to use custom policies, since th

  • Ruder Partap Singh 28 posts 142 karma points
    Mar 29, 2022 @ 03:54
    Ruder Partap Singh
    0

    i am using it like this

      var email = result.Principal.FindFirstValue(ClaimTypes.Email)
                            ?? result.Principal.FindFirstValue("emails")
                            ?? throw new Exception("Missing email claim");
    

    and its working for me,

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies