>        }
>        sessionConnection = 
> SessionConnection.builder().hostAndPort(HostAndPort.fromParts(host, 
> socket.getPort())).loginCredentials(
>                 loginCredentials).proxy(checkNotNull(proxyConfig, 
> "proxyConfig")).connectTimeout(timeout).sessionTimeout(timeout).build();
>     }
>  
> +   static boolean hasValidPrivateKey(LoginCredentials loginCredentials) {
> +      return loginCredentials.getPrivateKey() != null &&
> +         !loginCredentials.getPrivateKey().isEmpty() &&
> +         !loginCredentials.getPrivateKey().contains("Proc-Type: 
> 4,ENCRYPTED");
> +   }
> +
> +   static Connector getSSHAgentConnector() {
> +      JSch.setConfig("PreferredAuthentications", "publickey");

Hm...should we be doing this here, or earlier (and then once, hopefully), or 
when we try to connect?

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

Reply via email to