Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Protocol: Waku's Rate-Limiting Nullifier for privacy preserving spam protection #180

Open
1 of 8 tasks
mratsim opened this issue Feb 21, 2022 · 0 comments
Open
1 of 8 tasks
Labels
enhancement :shipit: New feature or request

Comments

@mratsim
Copy link
Owner

mratsim commented Feb 21, 2022

For privacy preserving p2p economic spam protection the Waku team designed rate-limiting nullifiers.

Prerequisites:

Note, the PoC is based on https://github.com/matter-labs/pairing (Zcash pairing "community edition") which uses ff "Community edition" which does support MULX/ADCX/ADOX assembly: https://github.com/matter-labs/ff/blob/aca3a18/ff_derive/src/asm/impls_4.rs, hence the following speedup of Constantine over pairing_ce are NOT due to the use of Assembly since the low-level playing field is even.

Pairing_CE cargo +nightly bench with fixes from matter-labs/pairing#8 (s/use pairing::/use pairing_ce::/g and s/G1::one()/<G1 as GenericCurveProjective>::one()/g, etc)
image

Constantine nimble bench_summary_bn254_snarks_clang
image

On the costliest operations, Constantine is 2.56x faster on G1 scalar mul, 8.95x faster on G2 scalar mul and 2.97x faster for pairing.
As the difference is algorithmic (described in optimizations.md, WASM would also benefit from those.

@mratsim mratsim added the enhancement :shipit: New feature or request label Feb 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement :shipit: New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant