Skip to content

ChaCha20Poly1305 adapter for WebAssembly and JS implementations

Notifications You must be signed in to change notification settings

hazae41/chacha20poly1305

Repository files navigation

ChaCha20Poly1305

ChaCha20Poly1305 adapter for WebAssembly and JS implementations

npm i @hazae41/chacha20poly1305

Node Package 📦

Features

Current features

  • 100% TypeScript and ESM
  • No external dependencies

Usage

WebAssembly

npm i @hazae41/chacha20poly1305.wasm
import { ChaCha20Poly1305 } from "@hazae41/chacha20poly1305"
import { ChaCha20Poly1305Wasm } from "@hazae41/chacha20poly1305.wasm"

await ChaCha20Poly1305Wasm.initBundled()

ChaCha20Poly1305.set(ChaCha20Poly1305.fromWasm(ChaCha20Poly1305Wasm))

Noble (JavaScript)

npm i @noble/ciphers
import { ChaCha20Poly1305 } from "@hazae41/chacha20poly1305"
import * as ChaChaNoble from "@noble/ciphers/chacha"

ChaCha20Poly1305.set(ChaCha20Poly1305.fromNoble(ChaChaNoble))

About

ChaCha20Poly1305 adapter for WebAssembly and JS implementations

Resources

Stars

Watchers

Forks

Packages

No packages published