Encryption / Decryption of app.config sections using RsaProtectedConfigurationProvider

后端 未结 3 1998
遇见更好的自我
遇见更好的自我 2021-01-05 11:13

During the installation of our program we run this method to encrpyt sections of the app.config:

// Get the application configuration file.
Configuratio         


        
3条回答
  •  爱一瞬间的悲伤
    2021-01-05 11:14

    I got this on an app.config that was running on a Windows Server set up as a SQL Server. It did not have IIS installed. The machine.config file listed RSAProtectedConfigurationProvider as the default, but when we looked in the two folders mentioned by Aliostad above the folders were empty.There were no keys installed. We used the aspnet_regiis tool to create a custom key. then we used it to grant access to the identity the batch job runs under. All of this was running cmd.exe and aspnet_regiis As Administrator.

提交回复
热议问题