com.atlassian.bamboo.plugins.ssh
Class SshConfig

java.lang.Object
  extended by com.atlassian.bamboo.plugins.ssh.SshConfig

public class SshConfig
extends java.lang.Object

This class parses SSH config files in the same way that SSH client does.


Field Summary
static java.io.File ID_DSA
           
static java.io.File ID_ECDSA
           
static java.io.File ID_RSA
           
static java.io.File[] KNOWN_PRIVATE_KEY_LOCATIONS
           
static java.io.File SSH_DIRECTORY
           
 
Constructor Summary
SshConfig(java.io.File... sshConfigs)
           
 
Method Summary
 ProxyConnectionData apply(ProxyConnectionData connectionData, java.lang.String defaultUserName)
          Returns new ProxyConnectionData object with null values overridden with config variables.
static SshConfig getDefaultSshConfig()
           
 java.util.Collection<Pair<java.io.File,java.lang.Long>> getParsedFiles()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SSH_DIRECTORY

public static final java.io.File SSH_DIRECTORY

ID_RSA

public static final java.io.File ID_RSA

ID_DSA

public static final java.io.File ID_DSA

ID_ECDSA

public static final java.io.File ID_ECDSA

KNOWN_PRIVATE_KEY_LOCATIONS

public static final java.io.File[] KNOWN_PRIVATE_KEY_LOCATIONS
Constructor Detail

SshConfig

public SshConfig(java.io.File... sshConfigs)
          throws java.io.IOException
Parameters:
sshConfigs - SSH configs to parse, in order of importance
Throws:
java.io.IOException
Method Detail

apply

public ProxyConnectionData apply(ProxyConnectionData connectionData,
                                 @Nullable
                                 java.lang.String defaultUserName)
                          throws java.io.IOException
Returns new ProxyConnectionData object with null values overridden with config variables. If user name is not supplied in the connection data, it will be overriden with defaultUserName

Returns:
Throws:
java.io.IOException

getDefaultSshConfig

public static SshConfig getDefaultSshConfig()
                                     throws java.io.IOException
Throws:
java.io.IOException

getParsedFiles

public java.util.Collection<Pair<java.io.File,java.lang.Long>> getParsedFiles()


Copyright © 2013 Atlassian Software Systems Pty Ltd. All Rights Reserved.