Skip to content

fix: Gates rolling hash of all supported hash algorithms to TLS1.2#5803

Merged
maddeleine merged 3 commits intoaws:mainfrom
maddeleine:hash_update
Mar 25, 2026
Merged

fix: Gates rolling hash of all supported hash algorithms to TLS1.2#5803
maddeleine merged 3 commits intoaws:mainfrom
maddeleine:hash_update

Conversation

@maddeleine
Copy link
Copy Markdown
Contributor

@maddeleine maddeleine commented Mar 25, 2026

Goal

Reducing the number of rolling hash algorithms in TLS1.3 mutual auth.

Why

This many hashes is costing us performance unnecessarily. See related issue for deeper explanation.

How

Gates the rolling hash of all supported hash algs to tls12 client auth case.

Callouts

Testing

Existing mTLS benchmark:
handshake-mTLS/s2n-tls time: [1.2180 ms 1.2202 ms 1.2227 ms]
change: [−0.7820% +0.1216% +1.0380%] (p = 0.81 > 0.05)
No change in performance detected.

With this change:
handshake-mTLS/s2n-tls time: [1.1726 ms 1.1750 ms 1.1780 ms]
change: [−4.8882% −4.0401% −3.1176%] (p = 0.00 < 0.05)
Performance has improved.

On my laptop this improves Mtls TLS13 handshake performance by ~4%.

Related

resolves #5802
release summary: Mtls TLS13 handshakes are ~4% faster
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions github-actions bot added the s2n-core team label Mar 25, 2026
@maddeleine maddeleine changed the title Gates rolling hash of all supported hash algorithms to TLS1.2 fix: Gates rolling hash of all supported hash algorithms to TLS1.2 Mar 25, 2026
@maddeleine maddeleine added this pull request to the merge queue Mar 25, 2026
Merged via the queue into aws:main with commit f57a3f6 Mar 25, 2026
56 of 58 checks passed
@maddeleine maddeleine deleted the hash_update branch March 25, 2026 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Too many required hash updates in mtls TLS1.3

3 participants