tlsconfig: add ChaCha20-Poly1305 cipher suites#153
Merged
thaJeztah merged 1 commit intodocker:mainfrom Mar 25, 2026
Merged
Conversation
The tlsconfig package provides a curated set of ciphers, with insecure ciphers removed; originally because Go stdlib included all ciphers by default (including insecure ones). Current versions of Go provide a much saner set of defaults, that closely matches the defaults as set in the tlsconfig package in this module; - Go 1.8 added ChaCha20-Poly1305 cipher suites - Go 1.22 removed RSA key-exchange suites from default list - Go 1.23 removed 3DES suites from default list | cipher | go-connections | stdlib defaults | |-----------------------------------------------|----------------------|--------------------| | TLS_RSA_WITH_AES_128_GCM_SHA256 | ✗ (insecure) | ✗ (since go1.22) | | TLS_RSA_WITH_AES_256_GCM_SHA384 | ✗ (insecure) | ✗ (since go1.22) | | TLS_RSA_WITH_AES_128_CBC_SHA | ✗ (insecure) | ✗ (since go1.22) | | TLS_RSA_WITH_AES_256_CBC_SHA | ✗ (insecure) | ✗ (since go1.22) | | TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA | ✗ (insecure) | ✗ (since go1.23) | | TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA | ✗ (legacy, non-AEAD) | ✓ | | TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA | ✗ (legacy, non-AEAD) | ✓ | | TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA | ✗ (legacy, non-AEAD) | ✓ | | TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA | ✗ (legacy, non-AEAD) | ✓ | | TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 | ✓ | ✓ | | TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 | ✓ | ✓ | | TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 | ✓ | ✓ | | TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 | ✓ | ✓ | | TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256 | ✗ | ✓ (added in go1.8) | | TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256 | ✗ | ✓ (added in go1.8) | From the above table, differences are; - Go still includes legacy, non-AEAD (TLS 1.2 CBC suites); these are still considered safe, but superseded by AEAD ciphers (AES-GCM, ChaCha20) and mainly retained for compatibility. - Go 1.8 and up added ChaCha20-Poly1305 cipher suites (see https://go-review.googlesource.com/c/go/+/30958). This patch adds the ChaCha20-Poly1305 cipher suites to align closer with the set of cipher suites provided by default in Go stdlib. Note that this only impacts TLS 1.2 (and older, but we don't allow TLS 1.1); for TLS 1.3, Go does not allow overriding the list of supported ciphers. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
robmry
approved these changes
Mar 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tlsconfig: add ChaCha20-Poly1305 cipher suites
The tlsconfig package provides a curated set of ciphers, with insecure
ciphers removed; originally because Go stdlib included all ciphers by
default (including insecure ones). Current versions of Go provide a much
saner set of defaults, that closely matches the defaults as set in the
tlsconfig package in this module;
From the above table, differences are;
but superseded by AEAD ciphers (AES-GCM, ChaCha20) and mainly retained for compatibility.
This patch adds the ChaCha20-Poly1305 cipher suites to align closer with the
set of cipher suites provided by default in Go stdlib.
Note that this only impacts TLS 1.2 (and older, but we don't allow TLS 1.1);
for TLS 1.3, Go does not allow overriding the list of supported ciphers.
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)