Repository navigation
tls-util: add handshake tests for trust store and client certs - #39428
Merged
Merged
Conversation
This was referenced Sep 30, 2026
jasonhernandez
marked this pull request as ready for review
October 1, 2026 16:42
Pin down the OpenSSL make_tls client behavior with real handshakes against an in-process OpenSSL server: verify-full with no sslrootcert trusts a CA installed via SSL_CERT_FILE, and the configured client certificate is presented to a server that requires one. Adds tempfile and tokio (both workspace deps) as dev-dependencies. Co-Authored-By: Claude Opus 5.5 <[email protected]>
jasonhernandez
force-pushed
the
jason/tls-stack-1-openssl-tests
branch
from
October 27, 2026 07:09
b94323f to
644a36c
Compare
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.
Motivation
First PR in the TLS migration stack replacing #36085: #39428 (this, OpenSSL handshake tests) → #39430 (rustls Postgres connector) → #39431 (channel binding) and #39432 (nightly public-CA check). #39433 (pgwire-common
TlsStreambridge) is independent, based on main.These tests pin down today's OpenSSL TLS client behavior in
mz-tls-utilahead of the rustls migration, which will extend each test with a rustls leg. Split out of #36085.Description
verify_full_trusts_default_store: withsslmode=verify-fulland nosslrootcert,make_tlstrusts a CA from the default store (SSL_CERT_FILE).client_certs_accepted:make_tlspresents the configured client certificate to a server that requires one.TestCa, a blocking OpenSSLSslAcceptorserver on a background thread, and connect/assert helpers.tempfileandtokioadded as dev-dependencies (both existing workspace deps). No production code changes.Verification
Ran the tests repeatedly under nextest. Confirmed each fails when its property is broken (no
SSL_CERT_FILE, no client cert).🤖 Generated with Claude Code