Bug 540415 - Provide public method in TransportHttp class allowing overriding the default sslVerify flag value initialized from the configuration
Summary: Provide public method in TransportHttp class allowing overriding the default ...
Status: NEW
Alias: None
Product: JGit
Classification: Technology
Component: JGit (show other bugs)
Version: 5.1   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-24 01:04 EDT by Lyor Goldstein CLA
Modified: 2018-10-26 05:20 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lyor Goldstein CLA 2018-10-24 01:04:48 EDT
The TransportHttp class has an internal (private) 'sslVerify' flag whose value is initialized from the repository's internal configuration. There may be cases where the TransportCallback registered for a GIT command may wish to override this flag and set it to a different value than the original configuration in the repository. E.g., the user's code accesses the remote repository via a different (HTTPS) URL than the one listed in the repository configuration but does not wish to verify the certificate due to whatever programming considerations.

All that is required is to add a couple of `isSslVerify/setSslVerify` public (!) methods to allow the TransportCallback to query this flag and modify it if the code wishes to do so.
Comment 1 Thomas Wolf CLA 2018-10-24 04:38:51 EDT
@Lyor: do you have an example of such a case?

Regarding sslVerify, see also bug 535850.
Comment 2 Thomas Wolf CLA 2018-10-26 05:20:49 EDT
Note that the user can configure this in the git config via http.<url>.sslVerify. Which can be placed in the user config, if desired.