gpt4 book ai didi

c# - IIS - 使用客户端证书接受的 SSL 设置

转载 作者:太空宇宙 更新时间:2023-11-03 13:24:54 25 4
gpt4 key购买 nike

我已经为 IIS 配置了 SSL,并将客户端证书设置为“接受”但是,当我尝试接受该网页时,浏览器不会提示输入客户端证书。

有了这段代码。 var cert = Request.ClientCertificate但是,我从来没有看到任何证书。

缺少什么?

IIS SSL Settings

IIS 7.0 - Windows 2008 32 位 - ASP.NET 4.0

最佳答案

通过对特定位置使用require 强制证书提示in web.config :

<location path="Home/CertPrompt">
<system.webServer>
<security>
<access sslFlags="Ssl, SslNegotiateCert" />
</security>
</system.webServer>
</location>

为此,您必须像这样修改您的 applicationHost.config(从拒绝访问 -> 允许):

<section name="access" overrideModeDefault="Allow" />` 

关于c# - IIS - 使用客户端证书接受的 SSL 设置,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35760582/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com