Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.equinox.console.ssh')
-rw-r--r--bundles/org.eclipse.equinox.console.ssh/META-INF/MANIFEST.MF1
-rw-r--r--bundles/org.eclipse.equinox.console.ssh/src/org/eclipse/equinox/console/internal/ssh/AuthorizedKeys.java14
2 files changed, 7 insertions, 8 deletions
diff --git a/bundles/org.eclipse.equinox.console.ssh/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.console.ssh/META-INF/MANIFEST.MF
index 19b397d1d..e23ad447f 100644
--- a/bundles/org.eclipse.equinox.console.ssh/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.console.ssh/META-INF/MANIFEST.MF
@@ -13,7 +13,6 @@ Import-Package: javax.security.auth;resolution:=optional,
javax.security.auth.login;resolution:=optional,
javax.security.auth.spi;resolution:=optional,
org.apache.felix.service.command;status=provisional;version="0.8.0",
- org.apache.mina.util;version="2.0.0";resolution:=optional,
org.apache.sshd.common;version="2.0.0";resolution:=optional,
org.apache.sshd.common.kex;version="2.0.0";resolution:=optional,
org.apache.sshd.common.keyprovider;version="2.0.0";resolution:=optional,
diff --git a/bundles/org.eclipse.equinox.console.ssh/src/org/eclipse/equinox/console/internal/ssh/AuthorizedKeys.java b/bundles/org.eclipse.equinox.console.ssh/src/org/eclipse/equinox/console/internal/ssh/AuthorizedKeys.java
index 43a974109..c512b8192 100644
--- a/bundles/org.eclipse.equinox.console.ssh/src/org/eclipse/equinox/console/internal/ssh/AuthorizedKeys.java
+++ b/bundles/org.eclipse.equinox.console.ssh/src/org/eclipse/equinox/console/internal/ssh/AuthorizedKeys.java
@@ -26,18 +26,18 @@ import java.security.spec.DSAPublicKeySpec;
import java.security.spec.InvalidKeySpecException;
import java.security.spec.RSAPublicKeySpec;
import java.util.ArrayList;
+import java.util.Base64;
import java.util.Collections;
import java.util.List;
import java.util.Scanner;
-import org.apache.mina.util.Base64;
/**
* Reader for 'authorized_keys' file as typically found on Unix systems.
*/
public class AuthorizedKeys {
- public static enum KeyType {
+ public enum KeyType {
RSA, DSA
}
@@ -48,7 +48,7 @@ public class AuthorizedKeys {
/**
* Creates a new instance.
- *
+ *
* @param message
* @param cause
*/
@@ -86,7 +86,7 @@ public class AuthorizedKeys {
/**
* Creates a new instance.
- *
+ *
* @throws FileNotFoundException
*/
public AuthorizedKeys(final String authorizedKeysFile) throws FileNotFoundException, IOException {
@@ -122,7 +122,7 @@ public class AuthorizedKeys {
/**
* Returns the keys.
- *
+ *
* @return the keys
*/
public List<PublicKey> getKeys() {
@@ -165,10 +165,10 @@ public class AuthorizedKeys {
// key
final int keyEndIdx = line.indexOf(' ');
if (keyEndIdx != -1) {
- key = Base64.decodeBase64(asBytes(line.substring(0, keyEndIdx)));
+ key = Base64.getDecoder().decode(asBytes(line.substring(0, keyEndIdx)));
line = line.substring(keyEndIdx + 1);
} else {
- key = Base64.decodeBase64(asBytes(line));
+ key = Base64.getDecoder().decode(asBytes(line));
}
// wrap key into byte buffer

Back to the top