pub trait MultiExponentiateBoundedExp<Exponent, BasesAndExponents>: Pow<Exponent> + Sized{
// Required method
fn multi_exponentiate_bounded_exp(
bases_and_exponents: &BasesAndExponents,
exponent_bits: usize,
) -> Self;
}
Expand description
Performs modular multi-exponentiation using Montgomery’s ladder.
exponent_bits
represents the number of bits to take into account for the exponent.
See: Straus, E. G. Problems and solutions: Addition chains of vectors. American Mathematical Monthly 71 (1964), 806–808.
NOTE: this value is leaked in the time pattern.
Required Methods§
sourcefn multi_exponentiate_bounded_exp(
bases_and_exponents: &BasesAndExponents,
exponent_bits: usize,
) -> Self
fn multi_exponentiate_bounded_exp( bases_and_exponents: &BasesAndExponents, exponent_bits: usize, ) -> Self
Calculates x1 ^ k1 * ... * xn ^ kn
.
Object Safety§
This trait is not object safe.