Home >

How to securing connection string of web.config

4. March 2011

Securing connection string in web.config is very important, while searching i found some simple methodes, for this you should be in the following directory:

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727>

For encryption:

aspnet_regiis.exe -pef "connectionStrings" "path of the site root directory" -prov "encryption provider"

Types of encryption provider:

DataProtectionConfigurationProvider
RSAProtectedConfigurationProvider
DPAPIProtectedConfigurationProvider

for e.g

aspnet_regiis.exe -pef "connectionStrings" "C:\Inetpub\wwwroot\bwl" -prov "DataProtectionConfigurationProvider"

For decryption:

aspnet_regiis.exe -pdf "connectionStrings" "path of the site root directory"

aspnet_regiis.exe -pdf "connectionStrings" "C:\Inetpub\wwwroot\bwl"

Thats all.

Technorati : ,
Del.icio.us : ,
Zooomr : ,
Flickr : ,

,

Add comment

  Country flag

biuquote
  • Comment
  • Preview
Loading