如何使用命令行工具加密配置文件的 System.ServiceModel 部分?(WCF 配置文件)
How to encrypt System.ServiceModel section of configuration file using command line tool?(WCF config file)
I am using aspnet_regiis -pef command for encrypting the same but getting error.
Error: The configuration section system.ServiceModel was not found
我是否需要为服务模型创建单独的部分然后加密?
<system.serviceModel>
<extensions>
<behaviorExtensions>.........
你可以在这里找到答案:
Encrypting app.config File
简而言之:
The aspnet_regiis will only encrypt configuration sections - so you
need to selectively encrypt those parts you need, like this:
cd C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
aspnet_regiis.exe -pef "system.serviceModel/bindings" .
aspnet_regiis.exe -pef "system.serviceModel/services" .
等等
I am using aspnet_regiis -pef command for encrypting the same but getting error.
Error: The configuration section system.ServiceModel was not found
我是否需要为服务模型创建单独的部分然后加密?
<system.serviceModel>
<extensions>
<behaviorExtensions>.........
你可以在这里找到答案: Encrypting app.config File
简而言之:
The aspnet_regiis will only encrypt configuration sections - so you need to selectively encrypt those parts you need, like this:
cd C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
aspnet_regiis.exe -pef "system.serviceModel/bindings" .
aspnet_regiis.exe -pef "system.serviceModel/services" .
等等