com.sshtools.j2ssh.openssh
Class RSAKeyInfo
java.lang.Object
com.sshtools.j2ssh.openssh.RSAKeyInfo
- All Implemented Interfaces:
- KeyInfo
public class RSAKeyInfo
- extends java.lang.Object
- implements KeyInfo
- Version:
- $Revision: 1.1 $
- Author:
- $author$
Constructor Summary |
RSAKeyInfo(java.math.BigInteger modulus,
java.math.BigInteger publicExponent,
java.math.BigInteger privateExponent,
java.math.BigInteger primeP,
java.math.BigInteger primeQ,
java.math.BigInteger primeExponentP,
java.math.BigInteger primeExponentQ,
java.math.BigInteger crtCoefficient)
Creates a new RSAKeyInfo object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
modulus
private java.math.BigInteger modulus
publicExponent
private java.math.BigInteger publicExponent
privateExponent
private java.math.BigInteger privateExponent
primeP
private java.math.BigInteger primeP
primeQ
private java.math.BigInteger primeQ
primeExponentP
private java.math.BigInteger primeExponentP
primeExponentQ
private java.math.BigInteger primeExponentQ
crtCoefficient
private java.math.BigInteger crtCoefficient
RSAKeyInfo
public RSAKeyInfo(java.math.BigInteger modulus,
java.math.BigInteger publicExponent,
java.math.BigInteger privateExponent,
java.math.BigInteger primeP,
java.math.BigInteger primeQ,
java.math.BigInteger primeExponentP,
java.math.BigInteger primeExponentQ,
java.math.BigInteger crtCoefficient)
- Creates a new RSAKeyInfo object.
- Parameters:
modulus
- publicExponent
- privateExponent
- primeP
- primeQ
- primeExponentP
- primeExponentQ
- crtCoefficient
-
getPrivateKeySpec
public java.security.spec.KeySpec getPrivateKeySpec()
- Specified by:
getPrivateKeySpec
in interface KeyInfo
- Returns:
getPublicKeySpec
public java.security.spec.KeySpec getPublicKeySpec()
- Specified by:
getPublicKeySpec
in interface KeyInfo
- Returns:
getCrtCoefficient
public java.math.BigInteger getCrtCoefficient()
- Returns:
getModulus
public java.math.BigInteger getModulus()
- Returns:
getPrimeExponentP
public java.math.BigInteger getPrimeExponentP()
- Returns:
getPrimeExponentQ
public java.math.BigInteger getPrimeExponentQ()
- Returns:
getPrimeP
public java.math.BigInteger getPrimeP()
- Returns:
getPrimeQ
public java.math.BigInteger getPrimeQ()
- Returns:
getPrivateExponent
public java.math.BigInteger getPrivateExponent()
- Returns:
getPublicExponent
public java.math.BigInteger getPublicExponent()
- Returns:
getRSAKeyInfo
public static RSAKeyInfo getRSAKeyInfo(SimpleASNReader asn)
throws java.io.IOException
- Parameters:
asn
-
- Returns:
-
- Throws:
java.io.IOException
writeRSAKeyInfo
public static void writeRSAKeyInfo(SimpleASNWriter asn,
RSAKeyInfo keyInfo)
- Parameters:
asn
- keyInfo
-