
Security News
PodRocket Podcast: Inside the Recent npm Supply Chain Attacks
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
@polkadot-labs/schnorrkel-wasm
Advanced tools
JavaScript WebAssembly (WASM) wrapper for the schnorrkel Rust crate
@polkadot-labs/schnorrkel-wasm
is a JavaScript WebAssembly (WASM) wrapper for the schnorrkel
Rust crate. This package provides a convenient interface for using Schnorrkel's cryptographic functions in JavaScript applications.
To install the library, you can use npm or yarn or pnpm:
npm install @polkadot-labs/schnorrkel-wasm
Here is an example of how to use the library:
import {
sr25519_secret_from_seed,
sr25519_pubkey,
sr25519_sign,
sr25519_verify,
} from "@polkadot-labs/schnorrkel-wasm"
const seed = new Uint8Array(32)
// Example usage for generating a sr25519 keypair
const privateKey = sr25519_secret_from_seed(seed)
const publicKey = sr25519_pubkey(privateKey)
// Example usage for signing a message
const message = new TextEncoder().encode("Hello")
const signature = sr25519_sign(publicKey, privateKey, message)
// Example usage for verifying a signature
const isValid = sr25519_verify(publicKey, message, signature)
console.log("Is valid:", isValid)
This project is licensed under the MIT License. See the LICENSE file for details.
FAQs
JavaScript WebAssembly (WASM) wrapper for the schnorrkel Rust crate
The npm package @polkadot-labs/schnorrkel-wasm receives a total of 614 weekly downloads. As such, @polkadot-labs/schnorrkel-wasm popularity was classified as not popular.
We found that @polkadot-labs/schnorrkel-wasm demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.