>     private final TrustManager[] trustManager;
>     private final Supplier<Credentials> creds;
>  
>     @Inject
> -   SSLContextWithKeysSupplier(Supplier<KeyStore> keyStore, @Provider 
> Supplier<Credentials> creds, HttpUtils utils,
> -         TrustAllCerts trustAllCerts) {
> -      this.keyStore = keyStore;
> -      this.trustManager = utils.trustAllCerts() ? new TrustManager[] { 
> trustAllCerts } : null;
> +   SSLContextWithKeysSupplier(@Provider Supplier<Credentials> creds, 
> TrustAllCerts trustAllCerts) {
> +      this.trustManager = new TrustManager[]{trustAllCerts};

TrustManager is responsible to validate the certificate chains, so if the 
certificate coming from the server is self-signed (not issued by a CA included 
in the JVM default trustStore) will fail the request. Also I don't think I'm 
affecting the entire JVM with that code, but only the jclouds-docker calls.

Again, whatever decision I make using `utils.trustAllCerts()` will be 
overridden by `OkHttpCommandExecutorServiceModule` and this will break things

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/113/files#r21887851

Reply via email to