diff options
| author | Shireesh Anjal <shireesh@gluster.com> | 2011-08-08 18:42:59 +0530 |
|---|---|---|
| committer | Shireesh Anjal <shireesh@gluster.com> | 2011-08-08 19:38:27 +0530 |
| commit | a71c77d8fe454b3b1b06792557cb02bb47478b5b (patch) | |
| tree | f83d74a40ad941cb281be23181161b2523aaa780 /src | |
| parent | 841e7040f46daa1797ef4a7eccc4d8493e3ab716 (diff) | |
Changed names of private/public key files to gluster.pem and gluster.pub
Diffstat (limited to 'src')
| -rw-r--r-- | src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/SshUtil.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/SshUtil.java b/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/SshUtil.java index 39dd42f9..7c14bf52 100644 --- a/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/SshUtil.java +++ b/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/SshUtil.java @@ -52,10 +52,9 @@ public class SshUtil { public static final String SSH_AUTHORIZED_KEYS_DIR_REMOTE = "/root/.ssh/"; private static final String SSH_AUTHORIZED_KEYS_FILE = "authorized_keys"; private static final String SSH_AUTHORIZED_KEYS_PATH_REMOTE = SSH_AUTHORIZED_KEYS_DIR_REMOTE + SSH_AUTHORIZED_KEYS_FILE; - public static final File PRIVATE_KEY_FILE = new File(SSH_AUTHORIZED_KEYS_DIR_LOCAL + "id_rsa"); - public static final File PUBLIC_KEY_FILE = new File(SSH_AUTHORIZED_KEYS_DIR_LOCAL + "id_rsa.pub"); + public static final File PRIVATE_KEY_FILE = new File(SSH_AUTHORIZED_KEYS_DIR_LOCAL + "gluster.pem"); + public static final File PUBLIC_KEY_FILE = new File(SSH_AUTHORIZED_KEYS_DIR_LOCAL + "gluster.pub"); // private static final String SCRIPT_DISABLE_SSH_PASSWORD_AUTH = "disable-ssh-password-auth.sh"; - private static final String PRIVATE_KEY_PASSPHRASE = "gluster"; private LRUCache<String, Connection> sshConnCache = new LRUCache<String, Connection>(10); // TODO: Make user name configurable @@ -177,7 +176,7 @@ public class SshUtil { + "]"); } - if (!conn.authenticateWithPublicKey(USER_NAME, PRIVATE_KEY_FILE, PRIVATE_KEY_PASSPHRASE)) { + if (!conn.authenticateWithPublicKey(USER_NAME, PRIVATE_KEY_FILE, null)) { throw new ConnectionException("SSH Authentication (public key) failed for server [" + conn.getHostname() + "]"); } |
