Reputation: 265
I have an identity server asp net core project deployed in Azure, i also have two asp net 5 mvc client using my identity server as SSO, and continuously i am getting(save in logs) an exception
The antiforgery token could not be decrypted.
Upvotes: 7
Views: 12234
Reputation: 569
We had the same error message
Antiforgery token validation failed. The antiforgery token could not be decrypted.
on an app which runs on disributed instances, we decreased the instance to one then problem is solved. This solution may save hours of someone one day.
Upvotes: 0
Reputation: 3275
We had similar issue today. We were able to resolve by persisting data protection keys to file system.
services.AddDataProtection()
.PersistKeysToFileSystem(new DirectoryInfo(@"\\UNC-PATH"));
Upvotes: 8