This has been working fine for months and just quit within the last couple of weeks. .NET 4.8 Web Forms app hosted in IIS: works fine when deployed to server, but fails locally. Two apps at virtual paths under same domain, both .NET 4.8, looks like this in IIS:

- domain.com
    - /virtualpath1
    - /virtualpath2

Virtualpath1 creates a FormsAuthentication cookie, and Virtualpath2 reads it.

I have the same machineKey values set at the domain level and at both virtual directory paths, HMACSHA256 + AES.

Just this past couple of weeks, suddenly when calling FormsAuthentication.Decrypt from Virtualpath2, I get the following error:

Error occurred during a cryptographic operation: at System.Web.Security.Cryptography.HomogenizingCryptoServiceWrapper.HomogenizeErrors(Func`2 func, Byte[] input) at System.Web.Security.FormsAuthentication.Decrypt(String encryptedTicket)

I've tried clearing cookies and browser cache to no avail. It also happens no matter what browser I use.

I'm wondering if there was a NuGet package upgrade that might have caused this to happen??

Any insight is greatly appreciated. Thank you.

0

There are 0 best solutions below