Gradle using old HTTPClient lib that doesn't support SNI

When using Gradle to build app that contains maven artefacts stored on HTTPS servers with wildcard certificates, then this error shows: hostname in certificate didn’t match . It seams that Gradle is using Apache HttpClient library 4.2.2 which does not support SNI extensions ( SNI extensions have been added in HttpClient library 4.3.2.

To make possible use of Gradle on HTTPS servers which use SNI, Apache HttpClient library should be upgraded to a newer version.

Here is the duplication of this issue with some additional links

We are also affected by this :confused:

We’ve needed to update HttpClient for other reasons, but there are some changes to the HttpClient API that may break our NTLM integration. We don’t have much code coverage for it, so the real work is making sure nothing breaks.

I think we had looked at updating to the latest, so if there’s an older version (e.g., 4.3.2) that doesn’t have as large of an impact and fixes your problems, I think a PR would be welcome if it can show that NTLM still works.