0
當我嘗試使用標準的RSA加密的MVC 3 web.config文件中的數據庫連接字符串加密,我收到以下錯誤信息:MVC 3「configProtectionProvider」屬性是不允許
的「configProtectionProvider」屬性是不允許的。
有關如何加密MVC 3網站中的數據庫連接字符串的任何想法?
代碼示例
<connectionStrings configProtectionProvider="RsaProtectedConfigurationProvider">
<EncryptedData Type="http://www.w3.org/2001/04/xmlenc#Element"
xmlns="http://www.w3.org/2001/04/xmlenc#">
<EncryptionMethod Algorithm="http://www.w3.org/2001/04/xmlenc#tripledes-cbc" />
<KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
<EncryptedKey xmlns="http://www.w3.org/2001/04/xmlenc#">
<EncryptionMethod Algorithm="http://www.w3.org/2001/04/xmlenc#rsa-1_5" />
<KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
<KeyName>
RSA Key
</KeyName>
</KeyInfo>
<CipherData>
<CipherValue>
WcFEbDX8VyLfAsVK8g6hZV....
</CipherValue>
</CipherData>
</EncryptedKey>
</KeyInfo>
<CipherData>
<CipherValue>
OpWQgQ....
</CipherValue>
</CipherData>
</EncryptedData>
</connectionStrings>
http://forums.asp.net/t/1771774.aspx/1 – RajeshKdev