ING-1336: Do not manually set server name in tls config#312
Merged
Conversation
3ee8f53 to
bd388e8
Compare
bd388e8 to
3d0be50
Compare
brett19
approved these changes
Nov 10, 2025
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.
When I added support for tls communication between CNG and the cluster I manually set the server name in the tls config. This means that every time we try to form a tls connection we use the same server name, the hostname from the connection string that CNG was given on start up. This will cause TLS handshakes to fail against any nodes other than the one that CNG was pointed to on start up because only that node's SAN list will contain a matching server name.
There was an underlying issue in the http transport for our agent that meant that the server name as not being automatically populated with the hostname from the address as it should be. That issue has been addressed so now we can remove the manual setting of the serverName and tls communication with the cluster will work correctly for all deployments.
Interestingly this did not cause any problems in Capella because we start CNG with a localhost connection string then all of the server node certificates have localhost in their SAN list.