public final class Rsa
extends java.lang.Object
| Constructor and Description |
|---|
Rsa() |
| Modifier and Type | Method and Description |
|---|---|
static java.math.BigInteger |
doPrivate(java.math.BigInteger input,
java.math.BigInteger modulus,
java.math.BigInteger privateExponent) |
static java.math.BigInteger |
doPrivateCrt(java.math.BigInteger input,
java.math.BigInteger privateExponent,
java.math.BigInteger primeP,
java.math.BigInteger primeQ,
java.math.BigInteger crtCoefficient) |
static java.math.BigInteger |
doPrivateCrt(java.math.BigInteger input,
java.math.BigInteger p,
java.math.BigInteger q,
java.math.BigInteger dP,
java.math.BigInteger dQ,
java.math.BigInteger qInv) |
static java.math.BigInteger |
doPublic(java.math.BigInteger input,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent) |
static Ssh2RsaPrivateCrtKey |
generateKey(int bits,
java.math.BigInteger e,
java.security.SecureRandom secRand) |
static Ssh2RsaPrivateCrtKey |
generateKey(int bits,
java.security.SecureRandom secRand) |
static java.math.BigInteger |
getPrimeExponent(java.math.BigInteger privateExponent,
java.math.BigInteger prime) |
static java.math.BigInteger |
padPKCS1(java.math.BigInteger input,
int type,
int padLen) |
static java.math.BigInteger |
removePKCS1(java.math.BigInteger input,
int type) |
public static java.math.BigInteger doPrivateCrt(java.math.BigInteger input,
java.math.BigInteger privateExponent,
java.math.BigInteger primeP,
java.math.BigInteger primeQ,
java.math.BigInteger crtCoefficient)
public static java.math.BigInteger doPrivateCrt(java.math.BigInteger input,
java.math.BigInteger p,
java.math.BigInteger q,
java.math.BigInteger dP,
java.math.BigInteger dQ,
java.math.BigInteger qInv)
public static java.math.BigInteger getPrimeExponent(java.math.BigInteger privateExponent,
java.math.BigInteger prime)
public static java.math.BigInteger padPKCS1(java.math.BigInteger input,
int type,
int padLen)
throws java.lang.IllegalStateException
java.lang.IllegalStateExceptionpublic static java.math.BigInteger removePKCS1(java.math.BigInteger input,
int type)
throws java.lang.IllegalStateException
java.lang.IllegalStateExceptionpublic static Ssh2RsaPrivateCrtKey generateKey(int bits, java.security.SecureRandom secRand) throws java.security.NoSuchAlgorithmException, java.security.spec.InvalidKeySpecException
java.security.NoSuchAlgorithmExceptionjava.security.spec.InvalidKeySpecExceptionpublic static Ssh2RsaPrivateCrtKey generateKey(int bits, java.math.BigInteger e, java.security.SecureRandom secRand) throws java.security.NoSuchAlgorithmException, java.security.spec.InvalidKeySpecException
java.security.NoSuchAlgorithmExceptionjava.security.spec.InvalidKeySpecExceptionpublic static java.math.BigInteger doPublic(java.math.BigInteger input,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent)
public static java.math.BigInteger doPrivate(java.math.BigInteger input,
java.math.BigInteger modulus,
java.math.BigInteger privateExponent)
Copyright © 2022. All rights reserved.