› NGINX
› NGINX Trac
› 3rd Party Modules
› Security Advisories
› CHANGES
› OpenResty
› ngx_lua
› Tengine
在线学习资源
› NGINX 开发从入门到精通
NGINX Modules
› ngx_echo
Dragonish3600
V2EX  ›  NGINX

TLS 1.3 似乎不支持 ECC 证书,那么,现在 ssl_ciphers 用什么顺序呢

  •  
  •   Dragonish3600 · May 3, 2019 · 7288 views
    This topic created in 2740 days ago, the information mentioned may be changed or developed.

    如题 TLS 1.1/1.2 的时代,为了加快 HTTPS 速度,都是部署 ECC/RSA 双证书,然后把 ECC 相关的 ciphers 放到前面,也就是把 ECDHE-ECDSA 的放前面,然后 RSA 的在后面。

    而 TLS 1.3 只支持下面 3 个 chiper,

    TLS_AES_256_GCM_SHA384 TLS_CHACHA20_POLY1305_SHA256 TLS_AES_128_GCM_SHA256

    那么,从访问速度的角度,是把 TLS1.2+ECC 放前面呢,还是 TLS1.3+RSA 放前面呢? 有没有啥推荐的 chiper 顺序

    9 replies  •  2019-05-04 15:25:23 +08:00
    Remember
    Remember
    May 3, 2019 via iPhone
    1
    cipher 跟证书是 RSA 还是 ECDSA 有啥关系?
    PS8LW2UFDC
    PS8LW2UFDC
    May 3, 2019❤️1
    2
    TLS 1.3 支持 ECC:
    https://i.loli.net/2019/05/03/5ccc4f144ca60.png


    而 TLS 1.3 貌似不支持自定义 chiper,这是 openssl 关于 TLS1.3 的文档:
    https://wiki.openssl.org/index.php/TLS1.3

    如有启用 TLS 1.3 问题也可以参考下这个:
    https://nodeedge.com/tls-1-3-issues.html
    Dragonish3600
    Dragonish3600
    OP
    May 3, 2019 via iPhone
    3
    @Remember 浏览器握手时冲前往后匹配,使用 ECC 证书需要把 ECD 的几个 ciphers 放前面
    Owenjia
    Owenjia
    May 3, 2019
    4
    参考下这个?
    https://beijinglug.club/wiki/doku.php?id=docs:tls_configuration
    Dragonish3600
    Dragonish3600
    OP
    May 3, 2019 via iPhone
    5
    @PS8LW2UFDC 看了下文档,写到

    The new ciphersuites are defined differently and do not specify the certificate type (e.g. RSA, DSA, ECDSA) or the key exchange mechanism (e.g. DHE or ECHDE). This has implications for ciphersuite configuration.


    看来只需要把 1.3 的几个放到前面就好了
    msg7086
    msg7086
    May 3, 2019
    6
    TLS_AES_256_GCM_SHA384
    TLS_CHACHA20_POLY1305_SHA256
    TLS_AES_128_GCM_SHA256

    这三个 Cipher 里哪个写了 RSA 了啊?

    另外,官方版的 Nginx 还没有加入 TLS1.3 选 Cipher 功能,需要自己打补丁。

    @PS8LW2UFDC SSL_CTX_set_ciphersuites 怕是被吃了 = =
    MonoLogueChi
    MonoLogueChi
    May 3, 2019 via Android
    7
    听这么一说,好像是的,我不熟的 RSA 证书会使用 tls1.3,但是 ECC 证书好像全都是 tls1.2 连接
    jinliming2
    jinliming2
    May 4, 2019 via iPhone
    8
    https://wiki.openssl.org/index.php/TLS1.3
    There are new ciphersuites that only work in TLSv1.3. The old ciphersuites cannot be used for TLSv1.3 connections and the new ones cannot be used in TLSv1.2 and below.
    The new ciphersuites are defined differently and do not specify the certificate type (e.g. RSA, DSA, ECDSA) or the key exchange mechanism (e.g. DHE or ECHDE). This has implications for ciphersuite configuration.
    就是说 1.3 的 cipher 跟证书类型无关了,放前面就行,旧的 cipher 在 1.3 里不兼容了,新的 cipher 在 1.2 里不兼容,所以如果浏览器支持前面几个的话,就肯定支持 1.3 的。
    PhA
    PhA
    May 4, 2019 via Android
    9
    我才知道居然和顺序还有关系 一直以为随便设置呢
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   3079 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 43ms · UTC 12:19 · PVG 20:19 · LAX 04:19 · JFK 07:19
    ♥ Do have faith in what you're doing.