Conversation
|
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.



This pull request updates the way client certificates are handled for secure remote API connections. The main change is to support loading a PEM bundle containing both the client certificate and private key, with improved error handling and new tests to ensure correct behavior. Documentation has also been updated to clarify the new expectations for certificate handling.
Certificate handling improvements:
CertPathoption now expects a PEM bundle that includes both the client certificate and private key, and the code loads this bundle usingtls.LoadX509KeyPair. Errors encountered during loading are now surfaced to the caller. (remote.go, [1] [2]httpClient()method now returns an error if the certificate bundle cannot be loaded, and this error is propagated through remote requests. (remote.go, remote.goL290-R343)Testing enhancements:
remote_transport_test.goto verify that the client correctly loads the certificate bundle, handles errors when the bundle is missing or invalid, and caches the HTTP client instance.Documentation updates:
README.mdto clarify thatCertPathshould point to a PEM bundle containing both the client certificate and private key, and revised the feature description to reflect this. [1] [2]