Web.config Encryption Error
asp.net, aspnet-regiis.exe, encryption, rsacryptoserviceprovider
Solution
I was getting the same issue with this failing:
aspnet_regiis -pa "NetFrameworkConfigurationKey" "{Domain}{Username}"
The above line was returning "The RSA key container was not found."
To fix this issue, I had to run Command Prompt as Administrator (open up Start > Accessories > then right-click Command Prompt and choose Run as administrator...). I had to do this even though my account was an administrator account.
Problem
Having problem with encryption. I gave full permissions to all users to RSA folders. I did ``` C:\>aspnet_regiis -pe "appSettings" -location "web.config" -prov "RsaProtectedCo nfigurationProvider" Encrypting configuration section... An error occurred executing the configuration section handler for appSettings. Failed to encrypt the section 'appSettings' using provider 'RsaProtectedConfigur ationProvider'. Error message from the provider: Object already exists. Failed! ``` Then I did ``` C:\>aspnet_regiis -pa "NetFrameworkConfigurationKey" "administrator" Adding ACL for access to the RSA Key container... The RSA key container was not found. Failed! ``` Followed by ``` C:\>aspnet_regiis -pc "NetFrameworkConfigurationKey" -exp Creating RSA Key container... The RSA key container could not be opened. Failed! ``` Nothing is working for me. Can anyone help? Thanks