If you use the aspnet_regiis.exe
tool, you will need to do this on each server separately, because the encryption married the server on which the encryption key was generated. So the short answer is that if you use this method, your DEV
key will not work when deployed to other environments.
However, if you want to be able to encrypt on one server and deploy it on other servers, reusing the same key, you need Encrypt Configuration Sections in ASP.NET 2.0 Using RSA . This works because you can export RSA keys. This method is especially useful in web farm scenarios (i.e., multiple front-end web servers).
source share