|
Bouncy Castle Cryptography Library 1.81 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.bouncycastle.pqc.legacy.crypto.mceliece.McElieceCipher
This class implements the McEliece Public Key cryptosystem (McEliecePKCS). It was first described in R.J. McEliece, "A public key cryptosystem based on algebraic coding theory", DSN progress report, 42-44:114-116, 1978. The McEliecePKCS is the first cryptosystem which is based on error correcting codes. The trapdoor for the McEliece cryptosystem using Goppa codes is the knowledge of the Goppa polynomial used to generate the code.
| Field Summary | |
int |
cipherTextSize
|
int |
maxPlainTextSize
|
static java.lang.String |
OID
The OID of the algorithm. |
| Constructor Summary | |
McElieceCipher()
|
|
| Method Summary | |
int |
getKeySize(McElieceKeyParameters key)
Return the key size of the given key object. |
void |
init(boolean forEncryption,
CipherParameters param)
|
byte[] |
messageDecrypt(byte[] input)
Decrypt a cipher text. |
byte[] |
messageEncrypt(byte[] input)
Encrypt a plain text. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String OID
public int maxPlainTextSize
public int cipherTextSize
| Constructor Detail |
public McElieceCipher()
| Method Detail |
public void init(boolean forEncryption,
CipherParameters param)
init in interface MessageEncryptorforEncryption - true if we are encrypting a signature, false
otherwise.param - key parameters for encryption or decryption.public int getKeySize(McElieceKeyParameters key)
key - the McElieceKeyParameters object
public byte[] messageEncrypt(byte[] input)
messageEncrypt in interface MessageEncryptorinput - the plain text
public byte[] messageDecrypt(byte[] input)
throws InvalidCipherTextException
messageDecrypt in interface MessageEncryptorinput - the cipher text
InvalidCipherTextException - if the cipher text is invalid.
|
Bouncy Castle Cryptography Library 1.81 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||