Skip to content

Commit

Permalink
Release 1.3.2.
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmillr committed Dec 11, 2021
1 parent 34dc3da commit 8d713fc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,10 @@ Use NPM in node.js / browser, or include single file from
> npm install @noble/secp256k1
```js
// Common.js and ECMAScript Modules (ESM)
import * as secp from "@noble/secp256k1";
// if you're using single file, use global variable nobleSecp256k1 instead
// If you're using single file, use global variable instead:
// nobleSecp256k1

(async () => {
// You pass either a hex string, or Uint8Array
Expand All @@ -39,6 +41,9 @@ import * as secp from "@noble/secp256k1";
const signature = await secp.sign(messageHash, privateKey);
const isSigned = secp.verify(signature, messageHash, publicKey);

// Canonical signatures
const signatureC = await secp.sign(messageHash, privateKey, { canonical: true });

// Supports Schnorr signatures
const rpub = secp.schnorr.getPublicKey(privateKey);
const rsignature = await secp.schnorr.sign(messageHash, privateKey);
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@noble/secp256k1",
"version": "1.3.1",
"version": "1.3.2",
"description": "Fastest JS implementation of secp256k1. Independently audited, high-security, 0-dependency ECDSA & Schnorr signatures",
"files": [
"lib"
Expand Down

0 comments on commit 8d713fc

Please sign in to comment.