What problem does it solve?
It helps you implement and evolve Anarchy’s browser-executed cryptography reliably, so encrypted messaging and stealth addressing work consistently across Rust, WebAssembly, and the frontend.
Core Features & Use Cases
- Wasm-bindgen boundary design for crypto APIs: define Rust/JS-safe inputs/outputs, avoid traps, and standardize error handling via
Result<T, JsError>.
- KZG-VSS hybrid scheme: implement KZG commitments/proofs with a VSS split/recover flow for verifiable storage-ready ciphertext sharding.
- Stealth addresses (EIP-5564 compatible): generate scan/spend keys, derive one-time stealth addresses, scan quickly for ownership, and keep backup semantics safe.
- Direct Message (DM) E2E encryption: encrypt, apply fixed-size bucket padding, envelope/inner-hash signing, fragment ciphertext for storage, and support deterministic decryption scanning.
- Frontend/Worker consumption pattern: consume the generated
pkg artifacts from Next.js and offload heavy proof/splitting/scanning tasks to a Worker pool to prevent UI freezes.
Quick Start
Ask the system to guide the implementation of a new wasm-bindgen API in packages/wasm-engine by updating the Rust module, re-exporting it from lib.rs, generating the pkg TypeScript types with wasm-pack, and verifying correctness with fixed test vectors for KZG/stealth/DM.