What is the effect of appName in the DpapiDataProtectionProvider constructor

In our class, IdentityManagerwe have the following line:

protectionProvider = new DpapiDataProtectionProvider("OurProduct");

What is the meaning of the last parameter and does it have any correlation with how the site is configured on IIS?

Background: We deploy the MVC5 site with a custom class IdentityManagerin the validation environment for a long time without problems, and now we are trying to complete the following problem when trying to reset user passwords:

System.Security.Cryptography.CryptographicException: The data protection operation was unsuccessful. This may have been caused by not having the user profile loaded for the current thread user context, which may be the case when the thread is impersonating.

Some solutions are described in the following thread: Generating a reset password token does not work on Azure Website

Everything is on one computer: IIS, Sql Server, browser for Firefox browser.

, , , , , ?

+4
1

, , , . , DataProtector.cs ( ) SHA 256.

, , . , , .

, , .

+1

All Articles