Using netsh, bind an SSL certificate to a port number is failing

前端 未结 9 2171
囚心锁ツ
囚心锁ツ 2020-12-08 19:57

I have followed the instructions in SSL with Self Hosted WCF Service. When I am trying to bind the certificate on Windows 7 using netsh as described in How to: Conf

9条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-08 20:06

    I noticed the following in your question. It may not solve the original issue, but the syntax here isn't correct.

    PS C:\> netsh http add sslcert ipport=0.0.0.0:8732 certhash=0000000000003ed9cd0c315bbb6dc1c08da5e6 appid={00112233-4455-6677-8899-AABBCCDDEEFF}
    Bad numeric constant: 224.
    At line:1 char:104
    + netsh http add sslcert ipport=0.0.0.0:8732 certhash=0000000000003ed9cd0c315bbb6dc1c08da5e6 appid={001 <<<< 12233-4455-6677-8899-AABBCCDDEEFF}
    + CategoryInfo          : ParserError: (224:String) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : BadNumericConstant
    

    Use this instead (with appid in a single quote '{}'):

    netsh http add sslcert ipport=0.0.0.0:8732 certhash=0000000000003ed9cd0c315bbb6dc1c08da5e6 appid='{00112233-4455-6677-8899-AABBCCDDEEFF}'
    

提交回复
热议问题