pub struct EncryptedPayload { /* private fields */ }Expand description
These are detached encrypted bytes, which means they have a 3IRON +
<2 bytes of header length> + <proto V3DocumentHeader> + IV + CIPHERTEXT.
Not created directly, use the TryFrom implementation instead.
Implementations§
Source§impl EncryptedPayload
impl EncryptedPayload
Sourcepub fn decrypt(self, key: &EncryptionKey) -> Result<PlaintextDocument, Error>
pub fn decrypt(self, key: &EncryptionKey) -> Result<PlaintextDocument, Error>
Decrypt a V3 detached document and verify its signature.
Trait Implementations§
Source§impl Clone for EncryptedPayload
impl Clone for EncryptedPayload
Source§fn clone(&self) -> EncryptedPayload
fn clone(&self) -> EncryptedPayload
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 EncryptedPayload
impl Debug for EncryptedPayload
Auto Trait Implementations§
impl !Freeze for EncryptedPayload
impl RefUnwindSafe for EncryptedPayload
impl Send for EncryptedPayload
impl Sync for EncryptedPayload
impl Unpin for EncryptedPayload
impl UnwindSafe for EncryptedPayload
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