public class RSASignature extends java.security.Signature implements Blindable
We assume that we already have an RSAEncryption primitive floating around.
| Constructor and Description |
|---|
RSASignature() |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.Object |
engineGetParameter(java.lang.String param)
SPI: There aren't any parameters
|
protected void |
engineInitSign(java.security.PrivateKey key)
SPI: Initializes this object for signing
using the private key
|
protected void |
engineInitVerify(java.security.PublicKey key)
SPI: Initializes this object for verification
using the given key
|
protected void |
engineSetParameter(java.lang.String param,
java.lang.Object value)
SPI: There aren't any parameters
|
protected byte[] |
engineSign()
SPI: Sign the input
|
protected void |
engineUpdate(byte b)
SPI: Single byte updates are forbidden
|
protected void |
engineUpdate(byte[] b,
int off,
int len)
SPI: Updates the data.
|
protected boolean |
engineVerify(byte[] signature)
SPI: Verify the input
|
void |
setBlindingInfo(java.security.SecureRandom rng,
CryptixRSAPublicKey pubKey)
set the RNG for blinding
|
protected byte[] |
sigToBytes(java.math.BigInteger num) |
clone, getAlgorithm, getInstance, getInstance, getInstance, getParameter, getParameters, getProvider, initSign, initSign, initVerify, initVerify, setParameter, setParameter, sign, sign, toString, update, update, update, update, verify, verifyprotected void engineInitVerify(java.security.PublicKey key)
throws java.security.InvalidKeyException
engineInitVerify in class java.security.SignatureSpikey - the public keyjava.security.InvalidKeyException - if the key class doesn't
implement CryptixRSAPublicKeyprotected void engineInitSign(java.security.PrivateKey key)
throws java.security.InvalidKeyException
engineInitSign in class java.security.SignatureSpikey - the private keyjava.security.InvalidKeyException - if the key class doesn't
implement than CryptixRSAPrivateKeyprotected void engineUpdate(byte b)
throws java.security.SignatureException
engineUpdate in class java.security.SignatureSpijava.security.SignatureException - if you do a single byte updateprotected void engineUpdate(byte[] b,
int off,
int len)
throws java.security.SignatureException
engineUpdate in class java.security.SignatureSpib - the buffer containing the dataoff - the offset into the bufferlen - the lengthjava.security.SignatureException - either if the algorithm
was improperly initialized or you try to call update
more than onceprotected byte[] engineSign()
throws java.security.SignatureException
engineSign in class java.security.SignatureSpijava.security.SignatureException - bad inputprotected boolean engineVerify(byte[] signature)
throws java.security.SignatureException
engineVerify in class java.security.SignatureSpijava.security.SignatureException - bad inputpublic void setBlindingInfo(java.security.SecureRandom rng,
CryptixRSAPublicKey pubKey)
setBlindingInfo in interface Blindablerng - a secure RNGprotected void engineSetParameter(java.lang.String param,
java.lang.Object value)
throws java.security.InvalidParameterException
engineSetParameter in class java.security.SignatureSpijava.security.InvalidParameterExceptionprotected java.lang.Object engineGetParameter(java.lang.String param)
throws java.security.InvalidParameterException
engineGetParameter in class java.security.SignatureSpijava.security.InvalidParameterExceptionprotected byte[] sigToBytes(java.math.BigInteger num)
Copyright (c) 1999-2001 Claymore Systems, Inc., All Rights Reserved.