Security News
JSR Working Group Kicks Off with Ambitious Roadmap and Plans for Open Governance
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
bls-eth-wasm
Advanced tools
This module is built with BLS_ETH=1
for Ethereum 2.0 spec.
bls.multiVerify
to verify all {sigs, pubs, msgs}.setETHmode(bls.ETH_MODE_DRAFT_07)
is default modebls.setETHmode(bls.ETH_MODE_DRAFT_07)
once after bls.init()
for BLS_ETH_MODE_DRAFT_07
defined at BLS12381G2_XMD:SHA-256_SSWU_RO_.setETHmode()
supports hash-to-curve defined at draft-irtf-cfrg-hash-to-curve at March 2020.The version v0.4.2
breaks backward compatibility of the entry point.
const bls = require('bls-eth-wasm')
const bls = require('bls-eth-wasm/browser')
<script src="https://herumi.github.io/bls-eth-wasm/browser/bls.js"></script>
Init as the followings:
bls.init(bls.BLS12_381)
(old) The new eth2.0 functions are supported. This mode will be removed in the future.
Init as the followings:
bls.init(bls.BLS12_381)
then, you can use the following functions.
bls-eth-wasm | eth2.0 spec name |
---|---|
SecretKey::sign | Sign |
PublicKey::verify | Verify |
Sign::aggregate | Aggregate |
Sign::fastAggregateVerify | FastAggregateVerify |
Sign::aggregateVerifyNoCheck | AggregateVerify |
The size of message must be 32 byte.
Check functions:
deserialize
check the correctness of the orderdeserialize
check the correctness of the ordersee bls
Install Emscripten.
cd src
git submodule update --init
make
node test.js
see bls-demo.
See browser/readme.md
to make browser/bls.js
.
const bls = require('bls-eth-wasm/browser')
modified new BSD License http://opensource.org/licenses/BSD-3-Clause
MITSUNARI Shigeo(herumi@nifty.com)
FAQs
BLS signature for Node.js by WebAssembly for Ethereum 2.0
The npm package bls-eth-wasm receives a total of 1,849 weekly downloads. As such, bls-eth-wasm popularity was classified as popular.
We found that bls-eth-wasm demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Security News
Research
An advanced npm supply chain attack is leveraging Ethereum smart contracts for decentralized, persistent malware control, evading traditional defenses.
Security News
Research
Attackers are impersonating Sindre Sorhus on npm with a fake 'chalk-node' package containing a malicious backdoor to compromise developers' projects.