gnu.crypto.sig.rsa

Class RSAPSSSignature

Implemented Interfaces:
Cloneable, ISignature

public class RSAPSSSignature
extends BaseSignature

The RSA-PSS signature scheme is a public-key encryption scheme combining the RSA algorithm with the Probabilistic Signature Scheme (PSS) encoding method.

The inventors of RSA are Ronald L. Rivest, Adi Shamir, and Leonard Adleman, while the inventors of the PSS encoding method are Mihir Bellare and Phillip Rogaway. During efforts to adopt RSA-PSS into the P1363a standards effort, certain adaptations to the original version of RSA-PSS were made by Mihir Bellare and Phillip Rogaway and also by Burt Kaliski (the editor of IEEE P1363a) to facilitate implementation and integration into existing protocols.

References:

  1. RSA-PSS Signature Scheme with Appendix, part B.
    Primitive specification and supporting documentation.
    Jakob Jonsson and Burt Kaliski.

Version:
$Revision: 1.7 $

Field Summary

Fields inherited from class gnu.crypto.sig.BaseSignature

md, privateKey, publicKey, schemeName

Fields inherited from interface gnu.crypto.sig.ISignature

SIGNER_KEY, SOURCE_OF_RANDOMNESS, VERIFIER_KEY

Constructor Summary

RSAPSSSignature()
Default 0-arguments constructor.
RSAPSSSignature(String mdName)
Constructs an instance of this object using the designated message digest algorithm as its underlying hash function, and having 0-octet salt.
RSAPSSSignature(String mdName, int sLen)
Constructs an instance of this object using the designated message digest algorithm as its underlying hash function.

Method Summary

Object
clone()
Returns a clone copy of this instance.
protected Object
generateSignature()
protected void
setupForSigning(PrivateKey k)
protected void
setupForVerification(PublicKey k)
protected boolean
verifySignature(Object sig)

Methods inherited from class gnu.crypto.sig.BaseSignature

clone, generateSignature, init, name, nextRandomBytes, setupForSigning, setupForVerification, setupSign, setupVerify, sign, update, update, verify, verifySignature

Constructor Details

RSAPSSSignature

public RSAPSSSignature()
Default 0-arguments constructor. Uses SHA-1 as the default hash and a 0-octet salt.


RSAPSSSignature

public RSAPSSSignature(String mdName)
Constructs an instance of this object using the designated message digest algorithm as its underlying hash function, and having 0-octet salt.

Parameters:
mdName - the canonical name of the underlying hash function.


RSAPSSSignature

public RSAPSSSignature(String mdName,
                       int sLen)
Constructs an instance of this object using the designated message digest algorithm as its underlying hash function.

Parameters:
mdName - the canonical name of the underlying hash function.
sLen - the desired length in octets of the salt to use for encoding / decoding signatures.

Method Details

clone

public Object clone()
Returns a clone copy of this instance.
Specified by:
clone in interface ISignature
Overrides:
clone in interface BaseSignature

Returns:
a clone copy of this instance.


generateSignature

protected Object generateSignature()
            throws IllegalStateException
Overrides:
generateSignature in interface BaseSignature


setupForSigning

protected void setupForSigning(PrivateKey k)
            throws IllegalArgumentException
Overrides:
setupForSigning in interface BaseSignature


setupForVerification

protected void setupForVerification(PublicKey k)
            throws IllegalArgumentException
Overrides:
setupForVerification in interface BaseSignature


verifySignature

protected boolean verifySignature(Object sig)
            throws IllegalStateException
Overrides:
verifySignature in interface BaseSignature


Copyright © 2001, 2002, 2003 Free Software Foundation, Inc. All Rights Reserved.