public class NTRUSigningPrivateKeyParameters extends AsymmetricKeyParameter
NTRUSigningPrivateKeyParameters.Basis of three polynomials each,
except the zeroth basis for which h is undefined.| Modifier and Type | Class and Description |
|---|---|
static class |
NTRUSigningPrivateKeyParameters.Basis
A NtruSign basis.
|
| Constructor and Description |
|---|
NTRUSigningPrivateKeyParameters(byte[] b,
NTRUSigningKeyGenerationParameters params)
Constructs a new private key from a byte array
|
NTRUSigningPrivateKeyParameters(java.io.InputStream is,
NTRUSigningKeyGenerationParameters params)
Constructs a new private key from an input stream
|
NTRUSigningPrivateKeyParameters(java.util.List<NTRUSigningPrivateKeyParameters.Basis> bases,
NTRUSigningPublicKeyParameters publicKey) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
NTRUSigningPrivateKeyParameters.Basis |
getBasis(int i)
Returns the
i-th basis |
byte[] |
getEncoded()
Converts the key to a byte array
|
NTRUSigningPublicKeyParameters |
getPublicKey() |
int |
hashCode() |
void |
writeTo(java.io.OutputStream os)
Writes the key to an output stream
|
isPrivatepublic NTRUSigningPrivateKeyParameters(byte[] b,
NTRUSigningKeyGenerationParameters params)
throws java.io.IOException
b - an encoded private keyparams - the NtruSign parameters to usejava.io.IOExceptionpublic NTRUSigningPrivateKeyParameters(java.io.InputStream is,
NTRUSigningKeyGenerationParameters params)
throws java.io.IOException
is - an input streamparams - the NtruSign parameters to usejava.io.IOExceptionpublic NTRUSigningPrivateKeyParameters(java.util.List<NTRUSigningPrivateKeyParameters.Basis> bases, NTRUSigningPublicKeyParameters publicKey)
public NTRUSigningPrivateKeyParameters.Basis getBasis(int i)
i-th basisi - the indexipublic NTRUSigningPublicKeyParameters getPublicKey()
public byte[] getEncoded()
throws java.io.IOException
java.io.IOExceptionpublic void writeTo(java.io.OutputStream os)
throws java.io.IOException
os - an output streamjava.io.IOExceptionpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Object