Web.Config encryption using RsaProtectedConfigurationProvider - “Bad Data” error

前端 未结 7 1731
悲哀的现实
悲哀的现实 2021-02-13 03:07

I am attempting to encrypt connection string values in the Web.Config file for an ASP.NET 2.0 web application, following the procedure described on MSDN. Using the RsaProtectedC

7条回答
  •  执笔经年
    2021-02-13 03:30

    I followed the approach listed below when I had Bad Data error while manual decryption.

    1. Add Remove and Clear tags in configProtectedData.
    2. Verify –pri was used while exporting key
    3. Also ensure that keyContainerName is same as the one used for regstering

    keyContainerName="MyKeys"

    CONFIG

    
      
    
        
    
    
    
         
    
      
    
    

    REFERENCE

    1. ConnectionString Encryption
    2. Where is RAS Key...

提交回复
热议问题