RSAOtherPrimeInfo
RSAOtherPrimeInfo (RSA 보조 소수 정보)
PKCS#1 v2.2 표준에 정의된 RSA의 OtherPrimeInfo 구조 안의 세 값(prime, exponent, coefficient)을 나타내는 클래스예요. 다중 소수 RSA 키에서 추가 소수들에 대한 정보를 담아요.
본문
RSA의 OtherPrimeInfo의 ASN.1 문법은 다음과 같아요.
OtherPrimeInfo ::= SEQUENCE {
prime INTEGER,
exponent INTEGER,
coefficient INTEGER
}
public class RSAOtherPrimeInfo
생성자는 세 값을 받아요.
public RSAOtherPrimeInfo(BigInteger prime, BigInteger exponent, BigInteger coefficient)
prime— 소수exponent— CRT(중국인 나머지 정리) 지수coefficient— CRT 계수
각 값은 getPrime(), getExponent(), getCoefficient()로 얻을 수 있어요. 값이 양수(0보다 큼)가 아니면 생성 시 IllegalArgumentException이 던져져요.
이 클래스는 RSAMultiPrimePrivateCrtKeySpec의 otherPrimeInfo 배열에 사용돼요.