encrypting web.config failed error

后端 未结 9 1128
囚心锁ツ
囚心锁ツ 2021-02-18 13:18

I know that ppl have already asked questions regarding encrypting web.config.

im also trying to encrypt my test config file, but im getting this error.

aspnet_re

9条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-18 13:37

    I was experiencing the same problem and here's what worked for me:

    1. add the aspnet_regiis tool's folder path to your %PATH% variable. This ensures that the tool is accessable from any folder in your command line. See this page for a brief explanation of how to add %PATH% variables: http://geekswithblogs.net/renso/archive/2009/10/21/how-to-set-the-windows-path-in-windows-7.aspx
    2. navigate to your web root folder (don't know if this is necessary but that's where I was navigated when I executed the command)
    3. execute the command with the -pe argument and the -app argument like such:

      aspnet_regiis -pe {section to encrypt} -app "{path from root folder to app, like: "/myappname", use quotes}

提交回复
热议问题