Package com.sshtools.j2ssh.openssh
Class RSAKeyInfo
- java.lang.Object
-
- com.sshtools.j2ssh.openssh.RSAKeyInfo
-
-
Constructor Summary
Constructors Constructor Description 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.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.math.BigIntegergetCrtCoefficient()java.math.BigIntegergetModulus()java.math.BigIntegergetPrimeExponentP()java.math.BigIntegergetPrimeExponentQ()java.math.BigIntegergetPrimeP()java.math.BigIntegergetPrimeQ()java.math.BigIntegergetPrivateExponent()java.security.spec.KeySpecgetPrivateKeySpec()java.math.BigIntegergetPublicExponent()java.security.spec.KeySpecgetPublicKeySpec()static RSAKeyInfogetRSAKeyInfo(SimpleASNReader asn)static voidwriteRSAKeyInfo(SimpleASNWriter asn, RSAKeyInfo keyInfo)
-
-
-
Constructor Detail
-
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-
-
-
Method Detail
-
getPrivateKeySpec
public java.security.spec.KeySpec getPrivateKeySpec()
- Specified by:
getPrivateKeySpecin interfaceKeyInfo- Returns:
-
getPublicKeySpec
public java.security.spec.KeySpec getPublicKeySpec()
- Specified by:
getPublicKeySpecin interfaceKeyInfo- 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-
-
-