UNPKG

noble-xwing

Version:

Typescript implementation of the X-Wing hybrid Post Quantum KEM using the noble library, as outlined in https://eprint.iacr.org/2024/039.

23 lines (22 loc) 664 B
import { KEM } from "./kem"; export type XwingKem = KEM<XwingSharedSecret, XwingCipherText, XwingPublicKey, XwingPrivateKey>; export declare const xwingKem: XwingKem; export type XwingPublicKey = { ecdhPublicKey: Uint8Array; mlKemPublicKey: Uint8Array; }; export type XwingPrivateKey = { ecdhPublicKey: Uint8Array; ecdhPrivateKey: Uint8Array; mlKemPrivateKey: Uint8Array; }; export type XwingCipherText = { mlKemCipherText: Uint8Array; ecdhCipherText: Uint8Array; }; export type XwingSharedSecret = { mlKemSharedSecret: Uint8Array; ecdhSharedSecret: Uint8Array; ecdhCipherText: Uint8Array; ecdhPublicKey: Uint8Array; };