org.kuali.common.util.secure
Class SSHUtils
java.lang.Object
org.kuali.common.util.secure.SSHUtils
public class SSHUtils
- extends Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
STRICT_HOST_KEY_CHECKING
public static final String STRICT_HOST_KEY_CHECKING
- See Also:
- Constant Field Values
NO
public static final String NO
- See Also:
- Constant Field Values
PRIVATE_KEY_DEFAULTS
public static final List<String> PRIVATE_KEY_DEFAULTS
DEFAULT_CONFIG_FILE
public static final File DEFAULT_CONFIG_FILE
DEFAULT_PORT
public static final int DEFAULT_PORT
- See Also:
- Constant Field Values
DEFAULT_KNOWN_HOSTS
public static final File DEFAULT_KNOWN_HOSTS
SSHUtils
public SSHUtils()
isValidPort
public static final boolean isValidPort(int port)
- Return true if
port >= 1
and port <= 65535
, false otherwise.
addPort
public static final void addPort(List<String> args,
String portOption,
int port,
int defaultPort)
addOptions
public static final void addOptions(List<String> args,
Properties options)
addConfigFile
public static final void addConfigFile(List<String> args,
File configFile,
File defaultConfigFile)
addIdentityFile
public static final void addIdentityFile(List<String> args,
File identityFile)
getPrivateKeys
public static final List<File> getPrivateKeys(File config)
- Return a non-null list containing any private keys found by examining default private key locations in
~/.ssh
and
parsing config
. Any files returned by this method are guaranteed to exist and be readable.
getDefaultPrivateKeys
public static final List<File> getDefaultPrivateKeys()
- Return a non-null list containing any private keys found by examining default private key locations in
~/.ssh
and
parsing ~/.ssh/config
. Any files returned by this method are guaranteed to exist and be readable.
getDefaultOptions
public static final Properties getDefaultOptions()
getExistingAndReadable
public static final List<File> getExistingAndReadable(List<String> filenames)
getFilenames
public static final List<String> getFilenames(File config)
getIdentityFileLines
public static final List<String> getIdentityFileLines(List<String> lines)
getFilenames
public static final List<String> getFilenames(List<String> identityFileLines)
Copyright © 2010-2013 The Kuali Foundation. All Rights Reserved.