Struct nucypher_core::ReencryptionResponse
source · [−]pub struct ReencryptionResponse { /* private fields */ }Expand description
A response from Ursula with reencrypted capsule frags.
Implementations
sourceimpl ReencryptionResponse
impl ReencryptionResponse
sourcepub fn new(
signer: &Signer,
capsules: &[Capsule],
vcfrags: impl IntoIterator<Item = VerifiedCapsuleFrag>
) -> Self
pub fn new(
signer: &Signer,
capsules: &[Capsule],
vcfrags: impl IntoIterator<Item = 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
sourceimpl Clone for ReencryptionResponse
impl Clone for ReencryptionResponse
sourcefn clone(&self) -> ReencryptionResponse
fn clone(&self) -> ReencryptionResponse
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for ReencryptionResponse
impl Debug for ReencryptionResponse
sourceimpl<'de> Deserialize<'de> for ReencryptionResponse
impl<'de> Deserialize<'de> for ReencryptionResponse
sourcefn 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
sourceimpl PartialEq<ReencryptionResponse> for ReencryptionResponse
impl PartialEq<ReencryptionResponse> for ReencryptionResponse
sourcefn eq(&self, other: &ReencryptionResponse) -> bool
fn eq(&self, other: &ReencryptionResponse) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &ReencryptionResponse) -> bool
fn ne(&self, other: &ReencryptionResponse) -> bool
This method tests for !=.
sourceimpl<'a> ProtocolObject<'a> for ReencryptionResponse
impl<'a> ProtocolObject<'a> for ReencryptionResponse
sourceimpl Serialize for ReencryptionResponse
impl Serialize for ReencryptionResponse
impl StructuralPartialEq for ReencryptionResponse
Auto Trait Implementations
impl RefUnwindSafe for ReencryptionResponse
impl Send for ReencryptionResponse
impl Sync for ReencryptionResponse
impl Unpin for ReencryptionResponse
impl UnwindSafe for ReencryptionResponse
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more