Package org.bouncycastle.pqc.crypto.ntru
Class NTRUKeyPairGenerator
java.lang.Object
org.bouncycastle.pqc.crypto.ntru.NTRUKeyPairGenerator
- All Implemented Interfaces:
AsymmetricCipherKeyPairGenerator
Key generator for NTRU.
Note: the init(KeyGenerationParameters) method only accepts NTRUKeyParameters. Otherwise, a
ClassCastException may occur.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionreturn an AsymmetricCipherKeyPair containing the generated keys.voidinit(KeyGenerationParameters param) intialise the key pair generator.
-
Constructor Details
-
NTRUKeyPairGenerator
public NTRUKeyPairGenerator()
-
-
Method Details
-
init
Description copied from interface:AsymmetricCipherKeyPairGeneratorintialise the key pair generator.- Specified by:
initin interfaceAsymmetricCipherKeyPairGenerator- Parameters:
param- the parameters the key pair is to be initialised with.
-
generateKeyPair
Description copied from interface:AsymmetricCipherKeyPairGeneratorreturn an AsymmetricCipherKeyPair containing the generated keys.- Specified by:
generateKeyPairin interfaceAsymmetricCipherKeyPairGenerator- Returns:
- an AsymmetricCipherKeyPair containing the generated keys.
-