pub trait HomomorphicMultiplication: EncryptionKey {
fn mul(
&self,
ciphertext_a: &Self::Ciphertext,
ciphertext_b: &Self::Ciphertext
) -> Self::Ciphertext;
fn pow(
&self,
ciphertext: &Self::Ciphertext,
input: &Self::Input
) -> Self::Ciphertext;
}
Expand description
Trait implemented by multiplicatively homomorphic cryptosystems
Required Methods
sourcefn mul(
&self,
ciphertext_a: &Self::Ciphertext,
ciphertext_b: &Self::Ciphertext
) -> Self::Ciphertext
fn mul(
&self,
ciphertext_a: &Self::Ciphertext,
ciphertext_b: &Self::Ciphertext
) -> Self::Ciphertext
Combines two ciphertexts so that their decrypted value reflects some multiplication operation
sourcefn pow(
&self,
ciphertext: &Self::Ciphertext,
input: &Self::Input
) -> Self::Ciphertext
fn pow(
&self,
ciphertext: &Self::Ciphertext,
input: &Self::Input
) -> Self::Ciphertext
Applies some operation on a ciphertext so that the decrypted value reflects some exponentiation with input