pub struct EscrowService;Expand description
The escrow service.
Implementations§
Source§impl EscrowService
impl EscrowService
Sourcepub fn escrow(
&self,
plaintext_key: &[u8],
recipient: &QuorumPublicKey,
escrowed_by: &str,
key_id: &str,
key_type: &str,
encapsulator: &dyn Encapsulator,
aead: &dyn Aead,
) -> Result<EscrowBlob, EscrowError>
pub fn escrow( &self, plaintext_key: &[u8], recipient: &QuorumPublicKey, escrowed_by: &str, key_id: &str, key_type: &str, encapsulator: &dyn Encapsulator, aead: &dyn Aead, ) -> Result<EscrowBlob, EscrowError>
Escrow a key (or any secret) to a recipient quorum.
Sourcepub fn recover(
&self,
blob: &EscrowBlob,
shared_secret: &[u8],
aead: &dyn Aead,
) -> Result<Vec<u8>, EscrowError>
pub fn recover( &self, blob: &EscrowBlob, shared_secret: &[u8], aead: &dyn Aead, ) -> Result<Vec<u8>, EscrowError>
Recover a key from a blob, given the recovered shared secret.
The caller is responsible for running the threshold decryption
ceremony to recover the shared secret (typically via
confium-tc-kem). This function takes the recovered secret
and performs the final AEAD decryption.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for EscrowService
impl RefUnwindSafe for EscrowService
impl Send for EscrowService
impl Sync for EscrowService
impl Unpin for EscrowService
impl UnsafeUnpin for EscrowService
impl UnwindSafe for EscrowService
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