Repository navigation
Backlog
Labels
Description
Summary
Add napi bindings and TypeScript wrappers for Ed448 signatures and X448 key exchange.
Blocked by: Cryptographic-API-Services/cas-lib#163 and the cas-lib release that contains it.
Upstream
cas-lib: Cryptographic-API-Services/cas-lib#163 (Curve448: Ed448 signatures and X448 key exchange). Not implemented in cas-lib yet; this issue tracks exposing it once it ships.
API shape in cas-lib: Mirrors the Ed25519 and X25519 APIs and result structs.
Scope
- Ed448 keygen, sign, verify (optional context string)
- X448 keygen and Diffie-Hellman
Feature-specific notes
- Mirror this repo's existing Ed25519 / X25519 surface (key-pair results, verify-with-public-key) so the two curves look the same to callers. The X448 shared secret is a secret.
Tests
Run the same vectors cas-lib uses through this repo's harness: Wycheproof ed448_test.json, x448_test.json; RFC 8032 §7.4 and RFC 7748 §6.2 vectors.
- Add any Wycheproof files to the
FILESarray inscripts/fetch-wycheproof.mjs, and any NIST files toscripts/fetch-nist.mjs(SHA-256-pinned).
Implementation notes (cas-typescript-sdk conventions, see CLAUDE.md)
- Bump
cas-libto the release that contains the feature (cargo update -p cas-libonly, one release per PR) and update the cas-lib version line inREADME.md. #[napi]functions insrc/<domain>/that returncrate::Result<T>and pass cas-lib results throughcrate::map_cas_err.- If cas-lib adds a
CasErrorvariant, add itsCAS_*code toErrorCodeand theCasErrorCodeenum insrc-ts/errors.ts(the build andevery_code_is_in_the_typescript_enumfail otherwise). - Run
npm run build:rustto regenerateindex.d.ts/index.js, then add the wrapper class insrc-ts/<domain>/and export it from the domainindex.tsandsrc-ts/index.ts. - Cover every new public method in
docs/EXAMPLES.md(run the coverage check from CLAUDE.md) and add a benchmark to the matching suite inbenchmarks/suites/.
Acceptance criteria
- CI green on Linux, Windows and macOS (
--lockedbuilds). - PR title follows Conventional Commits. Don't bump the version or edit
CHANGELOG.mdby hand; release-please does that.
Activity