Repository navigation
session client tls BUGFIX TLS with newer OpenSSL - #659
Merged
Merged
Conversation
The client passed the server address to X509_VERIFY_PARAM_set1_host() even when it was an IP address. That matches only dNSName SAN entries, so an address in an iPAddress entry was never accepted and connecting by address worked only through the fallback to the subject CN. OpenSSL 4.1 no longer consults the CN by default, so every connection by address failed with a hostname mismatch. An IP address is now matched against iPAddress SAN entries, as RFC 9525 requires; MbedTLS already does that. The test server certificates had no SAN, they are regenerated with the same keys and issuers.
OpenSSL 3.5+ built with enable-sslkeylog writes the secrets to SSLKEYLOGFILE on its own for every SSL_CTX. With the client and the server in one process, the file holds each secret three times (client, server and the libnetconf2 callback) and the exact count check failed on Fedora and Rocky 9. The duplicates are identical lines, so count each one once.
michalvasko
approved these changes
Dec 1, 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.
Fixes TLS client failures with newer OpenSSL. It contains 2 changes:
test_tlspasses with OpenSSL 3.5+ builds that writeSSLKEYLOGFILEon their own (Fedora, Rocky 9).With OpenSSL 4.1, server certificates without a SAN are rejected, so the test certificates are regenerated with one.