I have an existing application which generates owin identity token with machine key approach. The same token is used to authenticate various application. One of the application is now in asp.net core. Is there any way to use same owin generated identity token in asp.net core?
or we can decode that token manually in asp.net core
You can decrypt the Access Token returned from the authorization code flow directly by using
IDataProtector. we implement theIDataProtectorinterface and use theSystem.Web.Security.MachineKey.Unprotect method. To Make helper Method to decrypt the OWIN ticketTo get ClaimsIdentity and a Dictionary of Properties. we just create an instance and pass in the Token to get the decrypted Ticket
Above AuthenticationTicket itself contains the ClaimsIdentity and a Dictionary of Properties. refer IDataProtector Interface