Package com.sshtools.common.automate
Class RemoteIdentification
- java.lang.Object
-
- com.sshtools.common.automate.RemoteIdentification
-
public class RemoteIdentification extends java.lang.Object
- Version:
- $Revision: 1.19 $
- Author:
- $author$
-
-
Field Summary
Fields Modifier and Type Field Description static int
ADD_AUTHORIZEDKEY
protected org.apache.commons.logging.Log
log
static int
REMOVE_AUTHORIZEDKEY
-
Constructor Summary
Constructors Constructor Description RemoteIdentification(java.lang.String defaultName)
Creates a new RemoteIdentification object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addRule(RemoteIdentificationRule rule)
boolean
configureUserAccess(SftpClient sftp, java.lang.String serverId, java.lang.String system, java.lang.String username, SshPublicKey pk, java.lang.String authorizationFile, int mode)
boolean
configureUserAccess(SftpClient sftp, java.lang.String serverId, java.lang.String system, java.lang.String username, java.util.List keys, java.lang.String authorizationFile, int mode)
java.lang.String
getAuthorizedKeysDefaultPath()
AuthorizedKeysFormat
getAuthorizedKeysFormat()
java.lang.String
getDefaultName()
java.lang.String
getName(java.lang.String ident)
protected java.util.List
getRules()
protected void
setAuthorizedKeysDefaultPath(java.lang.String defaultPath)
protected void
setAuthorizedKeysFormat(java.lang.Class implementationClass)
protected boolean
testRules(java.lang.String ident)
-
-
-
Field Detail
-
ADD_AUTHORIZEDKEY
public static final int ADD_AUTHORIZEDKEY
- See Also:
- Constant Field Values
-
REMOVE_AUTHORIZEDKEY
public static final int REMOVE_AUTHORIZEDKEY
- See Also:
- Constant Field Values
-
log
protected org.apache.commons.logging.Log log
-
-
Method Detail
-
getRules
protected java.util.List getRules()
- Returns:
-
getDefaultName
public java.lang.String getDefaultName()
- Returns:
-
getName
public java.lang.String getName(java.lang.String ident) throws RemoteIdentificationException
- Parameters:
ident
-- Returns:
- Throws:
RemoteIdentificationException
-
addRule
protected void addRule(RemoteIdentificationRule rule)
- Parameters:
rule
-
-
testRules
protected boolean testRules(java.lang.String ident)
- Parameters:
ident
-- Returns:
-
setAuthorizedKeysFormat
protected void setAuthorizedKeysFormat(java.lang.Class implementationClass)
- Parameters:
implementationClass
-
-
setAuthorizedKeysDefaultPath
protected void setAuthorizedKeysDefaultPath(java.lang.String defaultPath)
- Parameters:
defaultPath
-
-
getAuthorizedKeysDefaultPath
public java.lang.String getAuthorizedKeysDefaultPath()
- Returns:
-
getAuthorizedKeysFormat
public AuthorizedKeysFormat getAuthorizedKeysFormat() throws RemoteIdentificationException
- Returns:
- Throws:
RemoteIdentificationException
-
configureUserAccess
public boolean configureUserAccess(SftpClient sftp, java.lang.String serverId, java.lang.String system, java.lang.String username, SshPublicKey pk, java.lang.String authorizationFile, int mode) throws RemoteIdentificationException
- Parameters:
sftp
-serverId
-system
-username
-pk
-authorizationFile
-mode
-- Returns:
- Throws:
RemoteIdentificationException
-
configureUserAccess
public boolean configureUserAccess(SftpClient sftp, java.lang.String serverId, java.lang.String system, java.lang.String username, java.util.List keys, java.lang.String authorizationFile, int mode) throws RemoteIdentificationException
- Parameters:
sftp
-serverId
-system
-username
-keys
-authorizationFile
-mode
-- Returns:
- Throws:
RemoteIdentificationException
-
-