Skip to content

Commit

Permalink
opt
Browse files Browse the repository at this point in the history
  • Loading branch information
0xmountaintop committed Aug 9, 2020
1 parent b829996 commit d58d270
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions benches/vdf/rsa_group.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,11 @@ fn eval(modulus: &Integer, g: &Integer, t: u64) -> (Integer, Integer) {
r2 = r.clone() * two.clone();
b = r2.clone().div_rem_floor(l.clone()).0;
r = r2.clone().div_rem_floor(l.clone()).1;
let pi_2 = pi.clone().pow_mod(&Integer::from(2), &modulus).unwrap();
let pi_2 = pi.clone().pow_mod(&two, &modulus).unwrap();
let g_b = g.clone().pow_mod(&b, &modulus).unwrap();
pi = pi_2 * g_b;
pi = Integer::from(pi.div_rem_floor(modulus.clone()).1)
}

pi = Integer::from(pi.div_rem_floor(modulus.clone()).1);
(y, pi)
}

Expand Down

0 comments on commit d58d270

Please sign in to comment.