Technology

Getting Type is not resolved for member Microsoft.IdentityModel.Claims.ClaimsPrincipal exception

Issue:

Getting runtime exception when running Visual Studio web project on cloud (Azure) using Telerik Sitefinity.

“Getting Type is not resolved for member Microsoft.IdentityModel.Claims.ClaimsPrincipal exception”

2014-11-02_15-17-01

Type is not resolved for member ‘Microsoft.IdentityModel.Claims.ClaimsPrincipal,Microsoft.IdentityModel, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35’.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Runtime.Serialization.SerializationException: Type is not resolved for member ‘Microsoft.IdentityModel.Claims.ClaimsPrincipal,Microsoft.IdentityModel, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35’.
Solution:

The issue is caused because Visual Studio & Telerik Sitefinity needs Microsoft Identity Foundation installed in order to resolve the requested type. This type is needed by cloud settings to support claims authentication. To resolve the issue open the bin folder of your project and find the
Microsoft.IdentityModel.dll file. Copy this file to C:\Program Files (x86)\Common Files\microsoft shared\DevServer\10.0 & C:\Program Files (x86)\Common Files\microsoft shared\DevServer\11.0 for 64 bit operating systems or to C:\Program Files\Common Files\microsoft shared\DevServer\10.0 for 32 bit operating systems. After you have copied the file restart the system.

Author

Jahanzaib Khan

Jahanzaib Khan is a Senior Software Engineer in Allied Consultants. With a experience over 4 years in ...................... , . He is one of the key resources of .Net framework for the organization.