【问题标题】:How to encrypt System.ServiceModel section of configuration file using command line tool?(WCF config file)如何使用命令行工具加密配置文件的 System.ServiceModel 部分?(WCF 配置文件)
【发布时间】:2016-04-15 11:14:03
【问题描述】:

我正在使用 aspnet_regiis -pef 命令进行加密,但出现错误。

错误:找不到配置部分 system.ServiceModel

我需要为服务模型创建单独的部分然后加密吗?

<system.serviceModel>
<extensions>
  <behaviorExtensions>.........

【问题讨论】:

    标签: asp.net wcf iis encryption web-config


    【解决方案1】:

    你可以在这里找到答案: Encrypting app.config File

    简而言之:

    aspnet_regiis 只会加密配置部分 - 所以你 需要选择性地加密那些你需要的部分,像这样:

    cd C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
    aspnet_regiis.exe -pef "system.serviceModel/bindings" .
    aspnet_regiis.exe -pef "system.serviceModel/services" .
    

    等等

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2010-09-06
      • 1970-01-01
      • 1970-01-01
      • 2010-10-08
      • 1970-01-01
      • 1970-01-01
      • 2022-01-13
      • 1970-01-01
      相关资源
      最近更新 更多