Package com.nimbusds.jose.jwk
Class RSAKey.OtherPrimesInfo
- java.lang.Object
-
- com.nimbusds.jose.jwk.RSAKey.OtherPrimesInfo
-
- All Implemented Interfaces:
Serializable
- Enclosing class:
- RSAKey
@Immutable public static class RSAKey.OtherPrimesInfo extends Object implements Serializable
Other Primes Info, represents the privateoth
parameter of a RSA JWK. This class is immutable.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description OtherPrimesInfo(Base64URL r, Base64URL d, Base64URL t)
Creates a new JWK Other Primes Info with the specified parameters.OtherPrimesInfo(RSAOtherPrimeInfo oth)
Creates a new JWK Other Primes Info from the specifiedjava.security.spec.RSAOtherPrimeInfo
instance.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Base64URL
getFactorCRTCoefficient()
The factor Chinese Remainder Theorem (CRT) coefficient (t
).Base64URL
getFactorCRTExponent()
Gets factor Chinese Remainder Theorem (CRT) exponent (d
).Base64URL
getPrimeFactor()
Gets the prime factor (r
).static List<RSAKey.OtherPrimesInfo>
toList(RSAOtherPrimeInfo[] othArray)
Converts the specified array ofjava.security.spec.RSAOtherPrimeInfo
instances to a list of JWK Other Prime Infos.
-
-
-
Constructor Detail
-
OtherPrimesInfo
public OtherPrimesInfo(Base64URL r, Base64URL d, Base64URL t)
Creates a new JWK Other Primes Info with the specified parameters.- Parameters:
r
- The prime factor. Must not benull
.d
- The factor Chinese Remainder Theorem (CRT) exponent. Must not benull
.t
- The factor Chinese Remainder Theorem (CRT) coefficient. Must not benull
.
-
OtherPrimesInfo
public OtherPrimesInfo(RSAOtherPrimeInfo oth)
Creates a new JWK Other Primes Info from the specifiedjava.security.spec.RSAOtherPrimeInfo
instance.- Parameters:
oth
- The RSA Other Primes Info instance. Must not benull
.
-
-
Method Detail
-
getPrimeFactor
public Base64URL getPrimeFactor()
Gets the prime factor (r
).- Returns:
- The prime factor.
-
getFactorCRTExponent
public Base64URL getFactorCRTExponent()
Gets factor Chinese Remainder Theorem (CRT) exponent (d
).- Returns:
- The factor Chinese Remainder Theorem (CRT) exponent.
-
getFactorCRTCoefficient
public Base64URL getFactorCRTCoefficient()
The factor Chinese Remainder Theorem (CRT) coefficient (t
).- Returns:
- The factor Chinese Remainder Theorem (CRT) coefficient.
-
toList
public static List<RSAKey.OtherPrimesInfo> toList(RSAOtherPrimeInfo[] othArray)
Converts the specified array ofjava.security.spec.RSAOtherPrimeInfo
instances to a list of JWK Other Prime Infos.- Parameters:
othArray
- Array of RSA Other Primes Info instances. May be benull
.- Returns:
- The corresponding list of JWK Other Prime Infos, or
empty list of the array was
null
.
-
-