title: Type is not resolved for member Microsoft.IdentityModel.Claims.ClaimsPrincipal
body: <p>I have an MVC 4 app deployed to an Azure cloud service that has worked for months.  Suddenly the app has stopped working, and I see 401 errors on a page that allows anonymous access.  Digging into the event log reveals this:</p>
  
  <pre><code>&lt;EventData&gt;
   &lt;Data&gt;System.AppDomain/50824127&lt;/Data&gt;
   &lt;Data&gt;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'. at System.Web.Hosting.ApplicationManager.GetUpdatedTotalCacheSize(Int64 sizeUpdate) at System.Web.Hosting.ObjectCacheHost.System.Runtime.Caching.Hosting.IMemoryCacheManager.UpdateCacheSize(Int64 size, MemoryCache memoryCache) at System.Runtime.Caching.CacheMemoryMonitor.GetCurrentPressure() at System.Runtime.Caching.MemoryMonitor.Update() at System.Runtime.Caching.MemoryCacheStatistics.CacheManagerThread(Int32 minPercent) at System.Threading.ExecutionContext.runTryCode(Object userData) at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading._TimerCallback.PerformTimerCallback(Object state)&lt;/Data&gt;
   &lt;Data&gt;w3wp&lt;/Data&gt;
   &lt;Data&gt;2548&lt;/Data&gt;
   &lt;/EventData&gt;
  </code></pre>
  
  <p>After hours and hours of troubleshooting and inspecting configurations, I am unable to figure out a reason why this would be happening.  The assembly, Microsoft.IdentityModel, 3.5.0.0 is in the bin folder in the deployment package, and the project has the correct references to the WIF nuget packages.  </p>
  
  <p>What's worse is that my project works in one azure cloud service, but not in another (which fails as described above).  There seem to be a limited number of related questions, such as <a href="https://stackoverflow.com/questions/13936103/type-is-not-resolved-for-member-microsoft-identitymodel-claims-claimsprincipal">Type is not resolved for member &quot;Microsoft.IdentityModel.Claims.ClaimsPrincipal,Microsoft.IdentityModel&quot;</a>, but this one has to do with running sitefinity on a developer workstation, and my problem is in the cloud.</p>
  
  <p>Any ideas?</p>