Trait paillier::traits::KeyGeneration
[−]
[src]
pub trait KeyGeneration<EK, DK> { fn keypair_with_modulus_size(big_length: usize) -> (EK, DK); fn keypair() -> (EK, DK) { ... } }
Secure generation of fresh key pairs.
Required Methods
fn keypair_with_modulus_size(big_length: usize) -> (EK, DK)
Generate fresh key pair with security level specified as the bit_length
of the modulus.
Currently recommended security level is a minimum of 2048 bits.
Provided Methods
fn keypair() -> (EK, DK)
Generate fresh key pair with currently recommended security level (2048 bit modulus).
Implementors
impl<I, S> KeyGeneration<EncryptionKey<I>, DecryptionKey<I>> for S where S: AbstractScheme<BigInteger=I>,
I: From<u64>,
I: FromStr,
I::Err: Debug,
I: Clone,
I: Samplable,
I: ModularArithmetic,
I: One,
I: PrimeSampable,
I: Mul<Output=I>,
&'a I: Mul<I, Output=I>,
I: Mul<&'b I, Output=I>,
&'a I: Mul<&'b I, Output=I>,
&'a I: Add<&'b I, Output=I>,
&'a I: Sub<I, Output=I>,
I: Sub<&'b I, Output=I>,
&'a I: Sub<&'b I, Output=I>,
I: Div<&'b I, Output=I>,
&'a I: Div<&'b I, Output=I>,
I: Rem<&'a I, Output=I>,
&'a I: Rem<&'b I, Output=I>