class PrivateX25519

Private X25519 key.

Methods

addAESRecipient(
verification_method: string,
jwe: JWE,
recipient: PublicX25519,
): JWERecipient
addChaCha20Recipient(
verification_method: string,
jwe: JWE,
recipient: PublicX25519,
): JWERecipient
decryptAES(
verification_method: string,
jwe: JWE,
): Uint8Array

Decrypt the provided JWE object using the X25519 key and the A256GCM algorithm.

decryptChaCha20(
verification_method: string,
jwe: JWE,
): Uint8Array

Decrypt the provided JWE object using the X25519 key and the XC20P algorithm.

free(): void

Get the did:key DID URL fragment value of the X25519 key.

Get the JWK value (with the private key) of the X25519 key.

Get the JWK value (without the private key) of the X25519 key.

toPublicKey(
id: string,
controller: string,
): PublicX25519

Derive an X25519 public key from the private key.