weird ClaimsIdentity vs WindowsIdentity question

lawrence whittemore asked on November 4, 2022 13:40

For our MVC Intranet site I am taking the current Active Directory user creating a kentico user for them and logging them in. Is it possible to still get the AD user information from the windows identity? When i use this

httpContextAccessor.HttpContext.User.Identity

it changes to ClaimsIdentity and Not WindowsIdentity

Hope that makes sense.

Recent Answers


Jeroen Fürst answered on November 22, 2022 12:54

Hi Lawrence,

I don't think that's possible. We have had similar implementations and used Microsoft's Grap REST API to retrieve additional Active Directory data. https://learn.microsoft.com/en-us/graph/api/resources/users?view=graph-rest-1.0

Hope this helps.

Cheers, Jeroen

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.