@Immutable public final class X25519Conscrypt extends Object implements X25519
We use the PKCS8 and X509 encodings of the private and the public keys, because they are supported by all JCE implementations and they are easier to convert from and to their raw 32-byte encodings.
X25519.KeyPair| Modifier and Type | Method and Description |
|---|---|
byte[] |
computeSharedSecret(byte[] privateValue,
byte[] peersPublicValue)
computeSharedSecret.
|
static X25519 |
create() |
X25519.KeyPair |
generateKeyPair()
generateKeyPair.
|
public static X25519 create() throws GeneralSecurityException
GeneralSecurityExceptionpublic X25519.KeyPair generateKeyPair() throws GeneralSecurityException
X25519generateKeyPair in interface X25519GeneralSecurityExceptionpublic byte[] computeSharedSecret(byte[] privateValue,
byte[] peersPublicValue)
throws GeneralSecurityException
X25519computeSharedSecret in interface X25519GeneralSecurityException