Comments (5)
Hi @0xvon . Thanks for pointing this out and proposing to help. The error is due to a deliberate design choice. It fails when all messages are being revealed which is quite unlikely in practice. But on rethinking, it should be allowed and the calling code should enforce this restriction if needed. So UnpackedBlindedMessages
needs to be changed. Also the test empty_proof
needs to be updated to not throw an error.
from crypto.
I agree with that! Let me try that issue. I'll send a PR today.
from crypto.
Btw, I found that ps_proof's prove_group bench uses the index i instead of j.
For that, when I bench for no less than 30 messages, index out of bounds
error causes.
Can I fix like this? I made sure that works.
--- a/benches/benches/ps_proof.rs
+++ b/benches/benches/ps_proof.rs
@@ -76,7 +76,7 @@ fn pok_sig_benchmark(c: &mut Criterion) {
let sig = &sigs_range[i];
let mut prove_group = c.benchmark_group(format!("Creating proof for Proof-of-knowledge of signature and corresponding multi-message of size {}", count));
- for (_j, r_count) in k.iter().enumerate() {
+ for (j, r_count) in k.iter().enumerate() {
prove_group.bench_with_input(
BenchmarkId::from_parameter(format!("Revealing {} messages", r_count)),
&r_count,
@@ -89,7 +89,7 @@ fn pok_sig_benchmark(c: &mut Criterion) {
.iter()
.enumerate()
.merge_join_by(
- revealed_indices[i].iter(),
+ revealed_indices[j].iter(),
|(m_idx, _), reveal_idx| m_idx.cmp(reveal_idx),
)
.map(|either| match either {
from crypto.
I created a PR for that two issues. Please check when you have time.
#21
from crypto.
@0xvon Thanks for the PR. And yes, you are correct about the loop index j
. Thanks for fixing that too.
from crypto.
Related Issues (11)
- First part of if condition redundant HOT 1
- C interface to "crypto" HOT 3
- Question: Composite Proofs HOT 4
- some crates use path to reference other creates, others do not: leading to "two version" problem HOT 1
- Can BBS+ signature be a delegatable credentials HOT 1
- `disjoint_witness_equalities` does not ensure disjoint lists HOT 3
- Question: Witness (terminology and implementation) HOT 3
- Benchmarks for BBS+/PS HOT 3
- Fixes to shamir HOT 4
- Consider replacing KOS with Softspoken HOT 5
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 crypto.