pub struct CandidateDecryption<G: Group> { /* private fields */ }
Expand description

Candidate for a VerifiableDecryption that is not yet verified. This presentation should be used for decryption data retrieved from an untrusted source.

Decryption data can be verified using Self::verify(). The threshold encryption scheme implemented in the sharing module has its own verification procedure in PublicKeySet.

Examples

See VerifiableDecryption for an example of usage.

Implementations

Deserializes decryption data from bytes. Returns None if the data is malformed.

Verifies this as decryption for ciphertext under key using the provided zero-knowledge proof.

Errors

Returns an error if proof does not verify.

Converts this candidate decryption into a VerifiableDecryption without verifying it. This only semantically correct if the data was verified in some other way.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Converts to this type from the input type.

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.