| Crates.io | wasm-crypto-box |
| lib.rs | wasm-crypto-box |
| version | 0.1.0 |
| created_at | 2025-12-30 21:22:53.758336+00 |
| updated_at | 2025-12-30 21:22:53.758336+00 |
| description | Browser-safe WebAssembly wrapper for ed25519 signing and verification |
| homepage | https://github.com/ |
| repository | https://github.com/ |
| max_upload_size | |
| id | 2013328 |
| size | 20,950 |
Browser-safe WASM wrapper around ed25519 for use in web apps and extensions.
getrandom)wasm-pack:wasm-pack build --target web
pkg output):import init, { generate_keypair, sign, verify } from './pkg/wasm_crypto_box.js';
await init();
const { secretKey, publicKey } = generate_keypair(); // Uint8Array fields
const msg = new TextEncoder().encode('hello');
const sig = sign(msg, secretKey);
const ok = verify(msg, sig, publicKey);
console.log('verified?', ok);
cargo check / cargo test (native tests)wasm-pack build --target web to generate pkg/ for browser usageBefore publishing, update Cargo.toml with your repository and homepage fields (if needed) and set an appropriate authors field.
Validate packaging locally:
cargo publish --dry-run
When ready, publish:
cargo publish
You can automate publishing on GitHub by setting a CARGO_REGISTRY_TOKEN secret and using the included .github/workflows/publish.yml which triggers on v* tags.
MIT