|
Bouncy Castle Cryptography Library 1.82 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.bouncycastle.crypto.engines.CramerShoupCoreEngine
Essentially the Cramer-Shoup encryption / decryption algorithms according to "A practical public key cryptosystem provably secure against adaptive chosen ciphertext attack." (Crypto 1998)
| Nested Class Summary | |
static class |
CramerShoupCoreEngine.CramerShoupCiphertextException
CS exception for wrong cipher-texts |
| Constructor Summary | |
CramerShoupCoreEngine()
|
|
| Method Summary | |
java.math.BigInteger |
convertInput(byte[] in,
int inOff,
int inLen)
|
byte[] |
convertOutput(java.math.BigInteger result)
|
java.math.BigInteger |
decryptBlock(CramerShoupCiphertext input)
|
CramerShoupCiphertext |
encryptBlock(java.math.BigInteger input)
|
int |
getInputBlockSize()
Return the maximum size for an input block to this engine. |
int |
getOutputBlockSize()
Return the maximum size for an output block to this engine. |
void |
init(boolean forEncryption,
CipherParameters param)
initialise the CramerShoup engine. |
void |
init(boolean forEncryption,
CipherParameters param,
java.lang.String label)
initialise the CramerShoup engine. |
protected java.security.SecureRandom |
initSecureRandom(boolean needed,
java.security.SecureRandom provided)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public CramerShoupCoreEngine()
| Method Detail |
public void init(boolean forEncryption,
CipherParameters param,
java.lang.String label)
forEncryption - whether this engine should encrypt or decryptparam - the necessary CramerShoup key parameters.label - the label for labelled CS as String
public void init(boolean forEncryption,
CipherParameters param)
forEncryption - whether this engine should encrypt or decryptparam - the necessary CramerShoup key parameters.public int getInputBlockSize()
public int getOutputBlockSize()
public java.math.BigInteger convertInput(byte[] in,
int inOff,
int inLen)
public byte[] convertOutput(java.math.BigInteger result)
public CramerShoupCiphertext encryptBlock(java.math.BigInteger input)
public java.math.BigInteger decryptBlock(CramerShoupCiphertext input)
throws CramerShoupCoreEngine.CramerShoupCiphertextException
CramerShoupCoreEngine.CramerShoupCiphertextException
protected java.security.SecureRandom initSecureRandom(boolean needed,
java.security.SecureRandom provided)
|
Bouncy Castle Cryptography Library 1.82 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||