Struct paillier::DecryptionKey [−][src]
pub struct DecryptionKey { /* fields omitted */ }
Private decryption key.
Trait Implementations
impl<'e> From<&'e DecryptionKey> for MinimalDecryptionKey
[src]
impl<'e> From<&'e DecryptionKey> for MinimalDecryptionKey
fn from(dk: &'e DecryptionKey) -> Self
[src]
fn from(dk: &'e DecryptionKey) -> Self
Performs the conversion.
impl<'e> From<MinimalDecryptionKey> for DecryptionKey
[src]
impl<'e> From<MinimalDecryptionKey> for DecryptionKey
fn from(dk: MinimalDecryptionKey) -> Self
[src]
fn from(dk: MinimalDecryptionKey) -> Self
Performs the conversion.
impl<'kp> From<&'kp Keypair> for DecryptionKey
[src]
impl<'kp> From<&'kp Keypair> for DecryptionKey
fn from(keypair: &'kp Keypair) -> DecryptionKey
[src]
fn from(keypair: &'kp Keypair) -> DecryptionKey
Performs the conversion.
impl Serialize for DecryptionKey
[src]
impl Serialize for DecryptionKey
fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>
[src]
fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>
Serialize this value into the given Serde serializer. Read more
impl<'de> Deserialize<'de> for DecryptionKey
[src]
impl<'de> Deserialize<'de> for DecryptionKey
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
[src]
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
impl<'m, 'd> Encrypt<DecryptionKey, RawPlaintext<'m>, RawCiphertext<'d>> for Paillier
[src]
impl<'m, 'd> Encrypt<DecryptionKey, RawPlaintext<'m>, RawCiphertext<'d>> for Paillier
fn encrypt(dk: &DecryptionKey, m: RawPlaintext<'m>) -> RawCiphertext<'d>
[src]
fn encrypt(dk: &DecryptionKey, m: RawPlaintext<'m>) -> RawCiphertext<'d>
Encrypt plaintext m
under key ek
into a ciphertext.
impl<'m, 'r, 'd> EncryptWithChosenRandomness<DecryptionKey, RawPlaintext<'m>, &'r Randomness, RawCiphertext<'d>> for Paillier
[src]
impl<'m, 'r, 'd> EncryptWithChosenRandomness<DecryptionKey, RawPlaintext<'m>, &'r Randomness, RawCiphertext<'d>> for Paillier
fn encrypt_with_chosen_randomness(
dk: &DecryptionKey,
m: RawPlaintext<'m>,
r: &'r Randomness
) -> RawCiphertext<'d>
[src]
fn encrypt_with_chosen_randomness(
dk: &DecryptionKey,
m: RawPlaintext<'m>,
r: &'r Randomness
) -> RawCiphertext<'d>
impl<'m, 'r, 'd> EncryptWithChosenRandomness<DecryptionKey, RawPlaintext<'m>, &'r PrecomputedRandomness, RawCiphertext<'d>> for Paillier
[src]
impl<'m, 'r, 'd> EncryptWithChosenRandomness<DecryptionKey, RawPlaintext<'m>, &'r PrecomputedRandomness, RawCiphertext<'d>> for Paillier
fn encrypt_with_chosen_randomness(
dk: &DecryptionKey,
m: RawPlaintext<'m>,
rn: &'r PrecomputedRandomness
) -> RawCiphertext<'d>
[src]
fn encrypt_with_chosen_randomness(
dk: &DecryptionKey,
m: RawPlaintext<'m>,
rn: &'r PrecomputedRandomness
) -> RawCiphertext<'d>
impl<'c, 'm> Decrypt<DecryptionKey, RawCiphertext<'c>, RawPlaintext<'m>> for Paillier
[src]
impl<'c, 'm> Decrypt<DecryptionKey, RawCiphertext<'c>, RawPlaintext<'m>> for Paillier
TODO
Efficient decryption using CRT based on Paillier99, section 7
fn decrypt(dk: &DecryptionKey, c: RawCiphertext<'c>) -> RawPlaintext<'m>
[src]
fn decrypt(dk: &DecryptionKey, c: RawCiphertext<'c>) -> RawPlaintext<'m>
Decrypt ciphertext c
using key dk
into a plaintext.
impl<'c, 'm> Decrypt<DecryptionKey, &'c RawCiphertext<'c>, RawPlaintext<'m>> for Paillier
[src]
impl<'c, 'm> Decrypt<DecryptionKey, &'c RawCiphertext<'c>, RawPlaintext<'m>> for Paillier
TODO
Efficient decryption using CRT based on Paillier99, section 7
fn decrypt(dk: &DecryptionKey, c: &'c RawCiphertext<'c>) -> RawPlaintext<'m>
[src]
fn decrypt(dk: &DecryptionKey, c: &'c RawCiphertext<'c>) -> RawPlaintext<'m>
Decrypt ciphertext c
using key dk
into a plaintext.
impl<'c, 'm> Open<DecryptionKey, RawCiphertext<'c>, RawPlaintext<'m>, Randomness> for Paillier
[src]
impl<'c, 'm> Open<DecryptionKey, RawCiphertext<'c>, RawPlaintext<'m>, Randomness> for Paillier
fn open(
dk: &DecryptionKey,
c: RawCiphertext<'c>
) -> (RawPlaintext<'m>, Randomness)
[src]
fn open(
dk: &DecryptionKey,
c: RawCiphertext<'c>
) -> (RawPlaintext<'m>, Randomness)
Open ciphertext c
using key dk
into a plaintext and a randomness.
impl<'c, 'm> Open<DecryptionKey, &'c RawCiphertext<'c>, RawPlaintext<'m>, Randomness> for Paillier
[src]
impl<'c, 'm> Open<DecryptionKey, &'c RawCiphertext<'c>, RawPlaintext<'m>, Randomness> for Paillier
fn open(
dk: &DecryptionKey,
c: &'c RawCiphertext<'c>
) -> (RawPlaintext<'m>, Randomness)
[src]
fn open(
dk: &DecryptionKey,
c: &'c RawCiphertext<'c>
) -> (RawPlaintext<'m>, Randomness)
Open ciphertext c
using key dk
into a plaintext and a randomness.
impl CorrectKey<EncryptionKey, DecryptionKey> for Paillier
[src]
impl CorrectKey<EncryptionKey, DecryptionKey> for Paillier
fn challenge(ek: &EncryptionKey) -> (Challenge, VerificationAid)
[src]
fn challenge(ek: &EncryptionKey) -> (Challenge, VerificationAid)
Generate challenge for given encryption key.
fn prove(
dk: &DecryptionKey,
challenge: &Challenge
) -> Result<CorrectKeyProof, CorrectKeyProofError>
[src]
fn prove(
dk: &DecryptionKey,
challenge: &Challenge
) -> Result<CorrectKeyProof, CorrectKeyProofError>
Generate proof given decryption key.
fn verify(
proof: &CorrectKeyProof,
va: &VerificationAid
) -> Result<(), CorrectKeyProofError>
[src]
fn verify(
proof: &CorrectKeyProof,
va: &VerificationAid
) -> Result<(), CorrectKeyProofError>
Verify proof.
impl Clone for DecryptionKey
[src]
impl Clone for DecryptionKey
fn clone(&self) -> DecryptionKey
[src]
fn clone(&self) -> DecryptionKey
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for DecryptionKey
[src]
impl Debug for DecryptionKey
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl PartialEq for DecryptionKey
[src]
impl PartialEq for DecryptionKey
fn eq(&self, other: &DecryptionKey) -> bool
[src]
fn eq(&self, other: &DecryptionKey) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &DecryptionKey) -> bool
[src]
fn ne(&self, other: &DecryptionKey) -> bool
This method tests for !=
.
Auto Trait Implementations
impl Send for DecryptionKey
impl Send for DecryptionKey
impl Sync for DecryptionKey
impl Sync for DecryptionKey