dfns / cggmp21

State-of-art threshold ECDSA in Rust
Apache License 2.0
41 stars 6 forks source link

Fix publish #81

Closed maurges closed 4 months ago

github-actions[bot] commented 4 months ago

Benchmark Result

Benchmarks ```text RUST_TESTS_SEED=ebf0177eacf1410350df8163dc124cdbbb75722a15dd2d0c5dd34d3926bb519d n = 3 Non-threshold DKG Protocol Performance: - Protocol took 421.98µs to complete In particular: - Stage: 3.13µs - Setup networking: 2.96µs (94.5%) - Unstaged: 171.00ns (5.5%) - Round 1: 146.02µs - Compute execution id: 4.26µs (2.9%) - Sample x_i, rid_i, chain_code: 64.05µs (43.9%) - Sample schnorr commitment: 59.43µs (40.7%) - Commit to public data: 17.96µs (12.3%) - Unstaged: 321.00ns (0.2%) - Round 2: 2.68µs - Hash received msgs (reliability check): 2.49µs (92.9%) - Unstaged: 191.00ns (7.1%) - Round 3: 300.00ns - Assert other parties hashed messages (reliability check): 171.00ns (57.0%) - Unstaged: 129.00ns (43.0%) - Round 4: 32.67µs - Validate decommitments: 30.16µs (92.3%) - Calculate chain_code: 941.00ns (2.9%) - Calculate challege rid: 1.16µs (3.6%) - Prove knowledge of `x_i`: 260.00ns (0.8%) - Unstaged: 150.00ns (0.5%) - Round 5: 237.18µs - Validate schnorr proofs: 236.93µs (99.9%) - Unstaged: 251.00ns (0.1%) Threshold DKG Protocol Performance: - Protocol took 1.24ms to complete In particular: - Stage: 2.05µs - Setup networking: 1.98µs (96.6%) - Unstaged: 69.00ns (3.4%) - Round 1: 202.58µs - Compute execution id: 822.00ns (0.4%) - Sample rid_i, schnorr commitment, polynomial, chain_code: 179.15µs (88.4%) - Commit to public data: 22.44µs (11.1%) - Unstaged: 160.00ns (0.1%) - Round 2: 1.07µs - Hash received msgs (reliability check): 912.00ns (85.1%) - Unstaged: 160.00ns (14.9%) - Round 3: 340.00ns - Assert other parties hashed messages (reliability check): 200.00ns (58.8%) - Unstaged: 140.00ns (41.2%) - Round 4: 773.12µs - Validate decommitments: 44.11µs (5.7%) - Validate data size: 291.00ns (0.0%) - Validate Feldmann VSS: 355.15µs (45.9%) - Compute rid: 491.00ns (0.1%) - Compute chain_code: 801.00ns (0.1%) - Compute Ys: 357.25µs (46.2%) - Compute sigma: 291.00ns (0.0%) - Calculate challenge: 14.26µs (1.8%) - Prove knowledge of `sigma_i`: 321.00ns (0.0%) - Unstaged: 160.00ns (0.0%) - Round 5: 265.42µs - Validate schnorr proofs: 263.94µs (99.4%) - Derive resulting public key and other data: 1.31µs (0.5%) - Unstaged: 162.00ns (0.1%) Auxiliary data generation protocol Protocol Performance: - Protocol took 9.54s to complete In particular: - Stage: 10.70µs - Retrieve auxiliary data: 161.00ns (1.5%) - Setup networking: 9.40µs (87.8%) - Precompute execution id and shared state: 1.06µs (9.9%) - Unstaged: 80.00ns (0.7%) - Round 1: 1.16s - Retrieve primes (p and q): 80.00ns (0.0%) - Compute paillier decryption key (N): 4.85µs (0.0%) - Generate auxiliary params r, λ, t, s: 9.03ms (0.8%) - Prove Πprm (ψˆ_i): 1.15s (99.2%) - Sample random bytes: 1.91µs (0.0%) - Compute hash commitment and sample decommitment: 299.56µs (0.0%) - Unstaged: 221.00ns (0.0%) - Round 2: 1.37µs - Hash received msgs (reliability check): 1.08µs (78.8%) - Unstaged: 291.00ns (21.2%) - Round 3: 371.00ns - Assert other parties hashed messages (reliability check): 211.00ns (56.9%) - Unstaged: 160.00ns (43.1%) - Round 4: 5.90s - Validate round 1 decommitments: 608.62µs (0.0%) - Validate П_prm (ψ_i): 2.30s (38.9%) - Add together shared random bytes: 1.60µs (0.0%) - Compute П_mod (ψ_i): 3.43s (58.2%) - Assemble security params for П_fac (ф_i): 11.32µs (0.0%) - Compute П_fac (ф_i^j): 171.13ms (2.9%) - Unstaged: 1.02µs (0.0%) - Round 5: 2.48s - Validate ψ_j (П_mod): 2.31s (93.1%) - Validate ф_j (П_fac): 171.84ms (6.9%) - Assemble auxiliary info: 146.33µs (0.0%) - Unstaged: 821.00ns (0.0%) Signing protocol Protocol Performance: - Protocol took 4.16s to complete In particular: - Stage: 140.35µs - Map t-out-of-n protocol to t-out-of-t: 69.73µs (49.7%) - Retrieve auxiliary data: 66.33µs (47.3%) - Precompute execution id and security params: 531.00ns (0.4%) - Setup networking: 3.61µs (2.6%) - Unstaged: 150.00ns (0.1%) - Round 1: 188.45ms - Generate local ephemeral secrets (k_i, y_i, p_i, v_i): 49.37µs (0.0%) - Encrypt G_i and K_i: 107.44ms (57.0%) - Prove ψ0_j: 80.97ms (43.0%) - Unstaged: 962.00ns (0.0%) - Round 2: 14.82µs - Hash received msgs (reliability check): 14.61µs (98.6%) - Unstaged: 211.00ns (1.4%) - Round 3: 2.23s - Assert other parties hashed messages (reliability check): 430.00ns (0.0%) - Verify psi0 proofs: 268.91ms (12.1%) - Sample random r, hat_r, s, hat_s, beta, hat_beta: 51.18µs (0.0%) - Encrypt D_ji: 70.33ms (3.2%) - Encrypt F_ji: 35.71ms (1.6%) - Encrypt hat_D_ji: 559.13ms (25.1%) - Encrypt hat_F_ji: 35.69ms (1.6%) - Prove psi_ji: 793.08ms (35.6%) - Prove psiˆ_ji: 209.41ms (9.4%) - Prove psi_prime_ji : 257.52ms (11.5%) - Unstaged: 1.55µs (0.0%) - Round 4: 1.56s - Retrieve auxiliary data: 4.87µs (0.0%) - Validate psi: 164.20ms (10.5%) - Validate hat_psi: 164.54ms (10.6%) - Validate psi_prime: 934.66ms (59.9%) - Compute Gamma, Delta_i, delta_i, chi_i: 215.02ms (13.8%) - Prove psi_prime_prime: 81.14ms (5.2%) - Unstaged: 461.00ns (0.0%) - Presig output: 184.94ms - Validate psi_prime_prime: 184.81ms (99.9%) - Calculate presignature: 134.25µs (0.1%) - Unstaged: 1.03µs (0.0%) - Partial signing: 9.75µs - Signature reconstruction: 201.63µs ```
github-actions[bot] commented 4 months ago

The spec was successfully compiled. PDF is available here.

survived commented 4 months ago

Why is it draft? Is there something else you wanted to do?

maurges commented 4 months ago

Because I was force-pushing changes to test workflow and not leave many commits