|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.i2p.crypto.ElGamalEngine
net.i2p.crypto.DummyElGamalEngine
public class DummyElGamalEngine
Fake ElG E and D, useful for when performance isn't being tested
Constructor Summary | |
---|---|
DummyElGamalEngine(I2PAppContext context)
The ElGamal engine should only be constructed and accessed through the application context. |
Method Summary | |
---|---|
byte[] |
decrypt(byte[] encrypted,
PrivateKey privateKey)
Decrypt the data |
byte[] |
encrypt(byte[] data,
PublicKey publicKey)
encrypt the data to the public key |
Methods inherited from class net.i2p.crypto.ElGamalEngine |
---|
main |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DummyElGamalEngine(I2PAppContext context)
Method Detail |
---|
public byte[] encrypt(byte[] data, PublicKey publicKey)
encrypt
in class ElGamalEngine
publicKey
- public key encrypt todata
- data to encrypt
public byte[] decrypt(byte[] encrypted, PrivateKey privateKey)
decrypt
in class ElGamalEngine
encrypted
- encrypted dataprivateKey
- private key to decrypt with
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |