use of java.security.spec.RSAMultiPrimePrivateCrtKeySpec in project robovm by robovm.
the class RSAMultiPrimePrivateCrtKeySpecTest method testGetPrimeExponentP.
/**
* Test for <code>getPrimeExponentP()</code> method<br>
* Assertion: returns prime exponent P
*/
public final void testGetPrimeExponentP() {
RSAMultiPrimePrivateCrtKeySpec ks = new RSAMultiPrimePrivateCrtKeySpec(BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, opi);
assertTrue(BigInteger.ONE.equals(ks.getPrimeExponentP()));
}
use of java.security.spec.RSAMultiPrimePrivateCrtKeySpec in project robovm by robovm.
the class RSAMultiPrimePrivateCrtKeySpecTest method testGetPrimeP.
/**
* Test for <code>getPrimeP()</code> method<br>
* Assertion: returns prime P
*/
public final void testGetPrimeP() {
RSAMultiPrimePrivateCrtKeySpec ks = new RSAMultiPrimePrivateCrtKeySpec(BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, opi);
assertTrue(BigInteger.ONE.equals(ks.getPrimeP()));
}
use of java.security.spec.RSAMultiPrimePrivateCrtKeySpec in project robovm by robovm.
the class RSAMultiPrimePrivateCrtKeySpecTest method testGetPrimeQ.
/**
* Test for <code>getPrimeQ()</code> method<br>
* Assertion: returns prime Q
*/
public final void testGetPrimeQ() {
RSAMultiPrimePrivateCrtKeySpec ks = new RSAMultiPrimePrivateCrtKeySpec(BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, opi);
assertTrue(BigInteger.ONE.equals(ks.getPrimeQ()));
}
use of java.security.spec.RSAMultiPrimePrivateCrtKeySpec in project robovm by robovm.
the class RSAMultiPrimePrivateCrtKeySpecTest method testRSAMultiPrimePrivateCrtKeySpec12.
/**
* Test #12 for
* <code>RSAMultiPrimePrivateCrtKeySpec(BigInteger modulus,
* BigInteger publicExponent,
* BigInteger privateExponent,
* BigInteger primeP,
* BigInteger primeQ,
* BigInteger primeExponentP,
* BigInteger primeExponentQ,
* BigInteger crtCoefficient,
* RSAOtherPrimeInfo[] otherPrimeInfo)
* </code> ctor<br>
* Assertion: constructs <code>RSAMultiPrimePrivateCrtKeySpec</code>
* object using valid parameters. Constructed object must be
* instance of RSAPrivateKeySpec.
*/
public final void testRSAMultiPrimePrivateCrtKeySpec12() {
KeySpec ks = new RSAMultiPrimePrivateCrtKeySpec(BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, opi);
assertTrue(ks instanceof RSAPrivateKeySpec);
}
use of java.security.spec.RSAMultiPrimePrivateCrtKeySpec in project robovm by robovm.
the class RSAMultiPrimePrivateCrtKeySpecTest method testRSAMultiPrimePrivateCrtKeySpec01.
// Test-cases:
/**
* Test #1 for
* <code>RSAMultiPrimePrivateCrtKeySpec(BigInteger modulus,
* BigInteger publicExponent,
* BigInteger privateExponent,
* BigInteger primeP,
* BigInteger primeQ,
* BigInteger primeExponentP,
* BigInteger primeExponentQ,
* BigInteger crtCoefficient,
* RSAOtherPrimeInfo[] otherPrimeInfo)
* </code> ctor<br>
* Assertion: constructs <code>RSAMultiPrimePrivateCrtKeySpec</code>
* object using valid parameters
*/
public final void testRSAMultiPrimePrivateCrtKeySpec01() {
KeySpec ks = new RSAMultiPrimePrivateCrtKeySpec(BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, opi);
assertTrue(ks instanceof RSAMultiPrimePrivateCrtKeySpec);
}
Aggregations