在调整 Web 代理代码时,我注意到如果我在具有 UAC(用户访问控制)的应用程序中运行代码,我会遇到异常
这是引发异常的位置:
sslStream.AuthenticateAsServer(_certificate, false, SslProtocols.Tls | SslProtocols.Ssl3 | SslProtocols.Ssl2, false);
这是我得到的错误(使用 UAC)
The server mode SSL must use a certificate with the associated private key.
第一个问题:为什么?
第二个问题:有其他选择吗?我真的很想在 UAC 中运行它(请注意 http 工作正常)