pub struct ReencryptionResponse { /* private fields */ }Expand description
A response from Ursula with reencrypted capsule frags.
Implementations§
Source§impl ReencryptionResponse
impl ReencryptionResponse
Sourcepub fn new<'a>(
signer: &Signer,
capsules_and_vcfrags: impl IntoIterator<Item = (&'a Capsule, VerifiedCapsuleFrag)>,
) -> Self
pub fn new<'a>( signer: &Signer, capsules_and_vcfrags: impl IntoIterator<Item = (&'a Capsule, VerifiedCapsuleFrag)>, ) -> Self
Creates and signs a new reencryption response.
Sourcepub fn verify(
self,
capsules: &[Capsule],
alice_verifying_key: &PublicKey,
ursula_verifying_key: &PublicKey,
policy_encrypting_key: &PublicKey,
bob_encrypting_key: &PublicKey,
) -> Result<Box<[VerifiedCapsuleFrag]>, VerificationError>
pub fn verify( self, capsules: &[Capsule], alice_verifying_key: &PublicKey, ursula_verifying_key: &PublicKey, policy_encrypting_key: &PublicKey, bob_encrypting_key: &PublicKey, ) -> Result<Box<[VerifiedCapsuleFrag]>, VerificationError>
Verifies the reencryption response and returns the contained kfrags on success.
Trait Implementations§
Source§impl Clone for ReencryptionResponse
impl Clone for ReencryptionResponse
Source§fn clone(&self) -> ReencryptionResponse
fn clone(&self) -> ReencryptionResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ReencryptionResponse
impl Debug for ReencryptionResponse
Source§impl<'de> Deserialize<'de> for ReencryptionResponse
impl<'de> Deserialize<'de> for ReencryptionResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ReencryptionResponse
impl PartialEq for ReencryptionResponse
Source§impl<'a> ProtocolObject<'a> for ReencryptionResponse
impl<'a> ProtocolObject<'a> for ReencryptionResponse
Source§impl Serialize for ReencryptionResponse
impl Serialize for ReencryptionResponse
impl StructuralPartialEq for ReencryptionResponse
Auto Trait Implementations§
impl Freeze for ReencryptionResponse
impl RefUnwindSafe for ReencryptionResponse
impl Send for ReencryptionResponse
impl Sync for ReencryptionResponse
impl Unpin for ReencryptionResponse
impl UnwindSafe for ReencryptionResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FromBytes for Twhere
T: for<'de> Deserialize<'de>,
impl<T> FromBytes for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more