[RESOLVED] How do you all encrypt connection strings in WEB.CONFIG?
How do you all encrypt connection strings in WEB.CONFIG?
TIA.
Re: How do you all encrypt connection strings in WEB.CONFIG?
Found this link - and it worked perfectly
https://techcommunity.microsoft.com/...on/ba-p/830094
Quote:
Run Command Prompt as Administrator
Go to C:\Windows\Microsoft.NET\Framework\v4.0.30319
Perform the command below to encrypt the connection string in your web.config:
ASPNET_REGIIS -pef "connectionStrings" "D:\inetpub\wwwroot\applicationFolder"
Open web.config and check if the connection string is encrypted
Test the site
If you want to decrypt it back, run this command:
ASPNET_REGIIS -pdf "connectionStrings" "D:\inetpub\wwwroot\applicationFolder"
Open the web.config and check if the connection string is decrypted
Re: [RESOLVED] How do you all encrypt connection strings in WEB.CONFIG?
This is what I used to do when I worked with asp.net
Note that I remember that this could work also with app.config but it's been sometimes so I'm not saying this with 100% certainty.
Also note that I'm not sure that you can decrypt on another server machine like that, so you might also want to read this:
https://docs.microsoft.com/en-us/pre...ectedfrom=MSDN
https://social.msdn.microsoft.com/Fo...csharplanguage