V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
NGINX
NGINX Trac
3rd Party Modules
Security Advisories
CHANGES
OpenResty
ngx_lua
Tengine
在线学习资源
NGINX 开发从入门到精通
NGINX Modules
ngx_echo
liuyinltemp
V2EX  ›  NGINX

nginx 双向 ssl 认证代码怎么写?

  •  
  •   liuyinltemp · 2020-07-15 11:40:49 +08:00 · 1595 次点击
    这是一个创建于 1353 天前的主题,其中的信息可能已经有所发展或是发生改变。
    如题,现在代码
    ssl_certificate cert/XX.crt;
    ssl_certificate_key cert/XX.key;
    ssl_trusted_certificate cert/chain.crt;
    双向认证时能用原来的数字证书吗?
    3 条回复    2020-07-16 10:03:31 +08:00
    xooass
        1
    xooass  
       2020-07-15 16:25:14 +08:00

    ssl_client_certificate ssl/cacert.pem;
    ssl_crl ssl/ca.crl;
    ssl_verify_client on;

    双向认证两边的证书是分开,互不关联的,你原来的数字证书那边啥都不用动
    liuyinltemp
        2
    liuyinltemp  
    OP
       2020-07-15 20:34:47 +08:00
    @xooass 个人想使用 免费的邮箱证书,不知道有什么要改,试了半天不行。Sectigo 的免费邮箱证书,ssl_client_certificate 就应该是它的根证书?
    liuyinltemp
        3
    liuyinltemp  
    OP
       2020-07-16 10:03:31 +08:00
    用自签的根证书签发后可以,但是用免费的邮箱证书不行。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4086 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 05:23 · PVG 13:23 · LAX 22:23 · JFK 01:23
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.