Need Encrypted connection string and stmp information in the web.config

后端 未结 1 744
遇见更好的自我
遇见更好的自我 2021-01-28 18:22

I want to keep encrypted connection string and stmp information in the web.config.

can I store Connection String and SMTP information in web.config encrypted and where I

1条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-28 18:59

    It's easy to do with aspnet_regiis.exe- look at the pe/pd/pef and pdf options. You can also do it programmatically. It works by encrypting a specific configuration section. In your case that is the connectionStrings and smtp sections.

    You can use either DPAPI or RSA and you can encrypt on either a machine wide basis or on a specific user account.

    0 讨论(0)
提交回复
热议问题