|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--iaik.pkcs.pkcs1.PKCS1AlgorithmParameterSpec | +--iaik.pkcs.pkcs1.RSAPssSaltParameterSpec
Parameter specification to may be used for specifying the saltLength parameter for the PKCS#1v2.1 RSASSA-PSS signature algorithm.
According PKCS#1v2.1
RSASSA-PSS
parameters consist
of hash algorithm id, mask generation function id, salt length and
trailer field:
RSASSA-PSS-params :: = SEQUENCE { hashAlgorithm [0] HashAlgorithm DEFAULT sha1, maskGenerationAlgorithm [1] MaskGenAlgorithm DEFAULT mgf1SHA1, saltLength [2] INTEGER DEFAULT 20, trailerField [3] TrailerField DEFAULT trailerFieldBC } HashAlgorithm ::= AlgorithmIdentifer { {OAEP-PSSDigestAlgorithms} } MaskGenAlgorithm ::= AlgorithmIdentifier { {PKCS1MGFAlgorithms} } TrailerField ::= INTEGER { trailerFieldBC(1) }The Java Cryptography Architecture, however, only allows to set the salt length as parameter and specifies all the other parameters by the algorithm standard name to be implemented by a corresponding PSS signature engine: A signature engine that implements the, for instance, "SHA1withRSAandMGF1" (in general: <digest>with<encryption>and<mgf>) PSS signature algorithm has to use SHA-1 as hash- and MGF1 as mask generation algorithm. The trailer field (0xBC) is fixed by the PKCS#1v2.1 standard and the salt length may be supplied as parameter (default 20 for the SHA-1 hash algorithm).
Field Summary | |
static int |
DEFAULT_SALT_LENGTH
Default salt length (20). |
protected int |
saltLength_
Salt length. |
Constructor Summary | |
RSAPssSaltParameterSpec()
Creates a RSAPssSaltParameterSpec with the default salt length value (20). |
|
RSAPssSaltParameterSpec(int saltLength)
Creates a RSAPssSaltParameterSpec for the given salt length. |
Method Summary | |
int |
getSaltLength()
Gets the salt length. |
String |
toString()
Gets a String representation of this RSAPssSaltParameterSpec. |
Methods inherited from class iaik.pkcs.pkcs1.PKCS1AlgorithmParameterSpec |
getSecureRandom, setSecureRandom |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int DEFAULT_SALT_LENGTH
protected int saltLength_
Constructor Detail |
public RSAPssSaltParameterSpec()
public RSAPssSaltParameterSpec(int saltLength)
saltLength
- the salt length value to be used.IllegalArgumentException
- if saltLength < 0Method Detail |
public int getSaltLength()
public String toString()
toString
in class Object
|
This Javadoc may contain text parts from Internet Standard specifications (RFC 2459, 3280, 3039, 2560, 1521, 821, 822, 2253, 1319, 1321, ,2630, 2631, 2268, 3058, 2984, 2104, 2144, 2040, 2311, 2279, see copyright note) and RSA Data Security Public-Key Cryptography Standards (PKCS#1,3,5,7,8,9,10,12, see copyright note). | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |