Class NTRUSigningPublicKeyParameters
java.lang.Object
org.bouncycastle.crypto.params.AsymmetricKeyParameter
org.bouncycastle.pqc.legacy.crypto.ntru.NTRUSigningPublicKeyParameters
- All Implemented Interfaces:
CipherParameters
A NtruSign public key is essentially a polynomial named
h
.-
Field Summary
-
Constructor Summary
ConstructorDescriptionNTRUSigningPublicKeyParameters
(byte[] b, NTRUSigningParameters params) Converts a byte array to a polynomialh
and constructs a new public keyReads a polynomialh
from an input stream and constructs a new public keyConstructs a new public key from a polynomial -
Method Summary
Modifier and TypeMethodDescriptionboolean
byte[]
Converts the key to a byte arrayint
hashCode()
void
writeTo
(OutputStream os) Writes the key to an output streamMethods inherited from class org.bouncycastle.crypto.params.AsymmetricKeyParameter
isPrivate
-
Field Details
-
h
-
-
Constructor Details
-
NTRUSigningPublicKeyParameters
Constructs a new public key from a polynomial- Parameters:
h
- the polynomialh
which determines the keyparams
- the NtruSign parameters to use
-
NTRUSigningPublicKeyParameters
Converts a byte array to a polynomialh
and constructs a new public key- Parameters:
b
- an encoded polynomialparams
- the NtruSign parameters to use
-
NTRUSigningPublicKeyParameters
public NTRUSigningPublicKeyParameters(InputStream is, NTRUSigningParameters params) throws IOException Reads a polynomialh
from an input stream and constructs a new public key- Parameters:
is
- an input streamparams
- the NtruSign parameters to use- Throws:
IOException
-
-
Method Details
-
getEncoded
public byte[] getEncoded()Converts the key to a byte array- Returns:
- the encoded key
-
writeTo
Writes the key to an output stream- Parameters:
os
- an output stream- Throws:
IOException
-
hashCode
public int hashCode() -
equals
-