com.sshtools.j2ssh.transport.publickey.rsa
Class SshRsaPrivateKey

java.lang.Object
  extended by com.sshtools.j2ssh.transport.publickey.SshPrivateKey
      extended by com.sshtools.j2ssh.transport.publickey.rsa.SshRsaPrivateKey

public class SshRsaPrivateKey
extends SshPrivateKey

Version:
$Revision: 1.1 $
Author:
$author$

Field Summary
(package private)  java.security.interfaces.RSAPrivateKey prvKey
           
(package private)  java.security.interfaces.RSAPublicKey pubKey
           
 
Constructor Summary
SshRsaPrivateKey(byte[] encoded)
          Creates a new SshRsaPrivateKey object.
SshRsaPrivateKey(java.security.interfaces.RSAPrivateKey prv, java.security.interfaces.RSAPublicKey pub)
          Creates a new SshRsaPrivateKey object.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 byte[] generateSignature(byte[] data)
           
 java.lang.String getAlgorithmName()
           
 int getBitLength()
           
 byte[] getEncoded()
           
 SshPublicKey getPublicKey()
           
 int hashCode()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

prvKey

java.security.interfaces.RSAPrivateKey prvKey

pubKey

java.security.interfaces.RSAPublicKey pubKey
Constructor Detail

SshRsaPrivateKey

public SshRsaPrivateKey(java.security.interfaces.RSAPrivateKey prv,
                        java.security.interfaces.RSAPublicKey pub)
Creates a new SshRsaPrivateKey object.

Parameters:
prv -
pub -

SshRsaPrivateKey

public SshRsaPrivateKey(byte[] encoded)
                 throws InvalidSshKeyException
Creates a new SshRsaPrivateKey object.

Parameters:
encoded -
Throws:
InvalidSshKeyException
Method Detail

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object
Parameters:
obj -
Returns:

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object
Returns:

getAlgorithmName

public java.lang.String getAlgorithmName()
Specified by:
getAlgorithmName in class SshPrivateKey
Returns:

getBitLength

public int getBitLength()
Specified by:
getBitLength in class SshPrivateKey
Returns:

getEncoded

public byte[] getEncoded()
Specified by:
getEncoded in class SshPrivateKey
Returns:

getPublicKey

public SshPublicKey getPublicKey()
Specified by:
getPublicKey in class SshPrivateKey
Returns:

generateSignature

public byte[] generateSignature(byte[] data)
Specified by:
generateSignature in class SshPrivateKey
Parameters:
data -
Returns: