if (context.getSecurityContext(SSH_SECURITY_CONTEXT) == null) {
String key = loadFromProperty(SSH_PRIVATE_KEY, false);
String pass = loadFromProperty(SSH_PRIVATE_KEY_PASS, false);
String user = loadFromProperty(SSH_USER_NAME, false);
if (key != null && user != null) {
SSHSecurityContextImpl ssh = new SSHSecurityContextImpl();
ssh.setKeyPass(pass);
ssh.setPrivateKeyLoc(key);
ssh.setUsername(user);
context.addSecurityContext(SSH_SECURITY_CONTEXT, ssh);
}
}
/*