Comments (1)
Yes, decompression currently does a full multiplication by the group order. See: https://github.com/filecoin-project/pairing/blob/master/src/bls12_381/ec.rs#L146 and https://github.com/filecoin-project/pairing/blob/master/src/bls12_381/ec.rs#L964
It's slow on G1 and really slow on G2. Assuming your orientation is public keys on G1 and signatures on G2 then yes it increases verification time significantly, although the pairings remain the worst part I think.
We're using the filecoin-project/pairing (paired) fork of zcash's pairing crate that support hashing-to-the-curve, as well as a bunch of trivial convenience tweaks that zcash never merged. I'd think everyone involved with that fork would support faster decompression and presumably the IRTF CFRG drafts for BLS signatures and hash-to-curve give good answers, but..
We should first replace the filecoin-project/pairing (paired) fork with some new fork that builds on zcash's new crate hierarchy. And send zcash PRs that they might or might not merge.
Algorand has a similar fork https://github.com/algorand/pairing-plus I'm unsure if it uses the newest zcash crates either, but it might support faster decompression and the hash-to-the-curve operation might somehow be better.
Ideally we should increase the compliance with the IRTF CFRG drafts throughout #5 although one should not do anything silly like using SHA2-HMACs everywhere.
As an aside, I'll caution you we're using zcash's crypto that does not currently provide constant time operations. I added key spiting to compensate but that's really more an orthogonal issue. See #3 There are several BLS crates based on AMCL, which does make constant-time claims. AMCL implements curves generically, which comes with upsides and downsides that I do not fully understand, but I know not everyone buys all the claims made by AMCL. ZCash will eventually provide constant-time code, at which point I'd trust their code more than AMCL.
I'd love a PR that added amcl_wrapper as an optional dependency used it only for signing, or more likely some fork of acml_wrapper that uses the AGPL's https://github.com/miracl/core see lovesh/amcl_rust_wrapper#6
from bls.
Related Issues (20)
- Improve serialization of Publickey and Signature HOT 2
- Improve serialization of Publickey and Signature HOT 1
- clean up the depenedancy so they are compatible with substrate HOT 2
- Implement Canonical De/Serialize for SecretKey HOT 1
- Alter the BEEFY structure to have only one aggergated BLS signature HOT 1
- Implement bls signature related functions for (substrate) host API
- Enable BEEFY Keystore to produce BLS signature HOT 2
- Reverse beefy messages to only support unaggregated BLS signatures in Beefy HOT 2
- Implement missing bls function for LocalKeystore HOT 1
- modify `client/beefy/src/worker.rs` to use either ECDSA or BLSnECDSA keystores
- How is `context` meant to be used when creating a new `Message`?
- Make ValidatorSet generic over public key type HOT 3
- Update BLS library to Pairing and Serialization changes HOT 3
- make thread_rng optional on std feature HOT 1
- Write test for BeefyECDSAandBLSKeystore HOT 1
- Implement Chaum Pederson Signature for Keypair HOT 2
- Make `keystore_vs_validator_set` test generic over the keystore HOT 4
- Clean up hash to curve branch and merge it with master HOT 1
- Expose Double Public Key scheme HOT 2
- Implement Serialization for `Double` Schemes HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bls.