Skip to content

feat: Ed448 signatures and X448 key exchange #201

Backlog

Description

@WingZer0o

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 FILES array in scripts/fetch-wycheproof.mjs, and any NIST files to scripts/fetch-nist.mjs (SHA-256-pinned).

Implementation notes (cas-typescript-sdk conventions, see CLAUDE.md)

  • Bump cas-lib to the release that contains the feature (cargo update -p cas-lib only, one release per PR) and update the cas-lib version line in README.md.
  • #[napi] functions in src/<domain>/ that return crate::Result<T> and pass cas-lib results through crate::map_cas_err.
  • If cas-lib adds a CasError variant, add its CAS_* code to ErrorCode and the CasErrorCode enum in src-ts/errors.ts (the build and every_code_is_in_the_typescript_enum fail otherwise).
  • Run npm run build:rust to regenerate index.d.ts / index.js, then add the wrapper class in src-ts/<domain>/ and export it from the domain index.ts and src-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 in benchmarks/suites/.

Acceptance criteria

  • CI green on Linux, Windows and macOS (--locked builds).
  • PR title follows Conventional Commits. Don't bump the version or edit CHANGELOG.md by hand; release-please does that.

Activity

  1. added
    enhancement
    rust
    on Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementrust

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions