pub struct Aes256GcmBitcode;
Trait Implementations§
Source§impl Debug for Aes256GcmBitcode
impl Debug for Aes256GcmBitcode
Source§impl Default for Aes256GcmBitcode
impl Default for Aes256GcmBitcode
Source§fn default() -> Aes256GcmBitcode
fn default() -> Aes256GcmBitcode
Returns the “default value” for a type. Read more
Source§impl Encryption for Aes256GcmBitcode
impl Encryption for Aes256GcmBitcode
type Cipher = AesGcm<Aes256, UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B0>>
type Scheme = Bitcode
fn encode<Data>(data: &Encrypted<Data>) -> Result<Vec<u8>, Box<dyn Error>>
fn decode<Data>(data: &[u8]) -> Result<Encrypted<Data>, Box<dyn Error>>
fn extract<'de, Data: Deserialize<'de> + Zeroize>( decrypted: &'de Decrypted<Data>, ) -> Result<Secret<Data>, Box<dyn Error>>
fn extract_exposed<'de, Data: Deserialize<'de>>( decrypted: &'de DecryptedExposed<Data>, ) -> Result<Data, Box<dyn Error>>
Source§fn encrypt<Data: Serialize>(
data: &Data,
key: &Key<Self::Cipher>,
) -> Result<Encrypted<Data>, Box<dyn Error>>
fn encrypt<Data: Serialize>( data: &Data, key: &Key<Self::Cipher>, ) -> Result<Encrypted<Data>, Box<dyn Error>>
convert the data to it’s serialized form and then encypt it using
[Cipher]
Source§fn decrypt<Data>(
encrypted: &Encrypted<Data>,
key: &GenericArray<u8, <Self::Cipher as KeySizeUser>::KeySize>,
) -> Result<Decrypted<Data>, Box<dyn Error>>
fn decrypt<Data>( encrypted: &Encrypted<Data>, key: &GenericArray<u8, <Self::Cipher as KeySizeUser>::KeySize>, ) -> Result<Decrypted<Data>, Box<dyn Error>>
decrypt the data to it’s serialized form, pre-emptively wraps data in
a Secret
Source§fn decrypt_exposed<Data>(
encrypted: &Encrypted<Data>,
key: &GenericArray<u8, <Self::Cipher as KeySizeUser>::KeySize>,
) -> Result<DecryptedExposed<Data>, Box<dyn Error>>
fn decrypt_exposed<Data>( encrypted: &Encrypted<Data>, key: &GenericArray<u8, <Self::Cipher as KeySizeUser>::KeySize>, ) -> Result<DecryptedExposed<Data>, Box<dyn Error>>
decrypt the data to it’s serialized form
Auto Trait Implementations§
impl Freeze for Aes256GcmBitcode
impl RefUnwindSafe for Aes256GcmBitcode
impl Send for Aes256GcmBitcode
impl Sync for Aes256GcmBitcode
impl Unpin for Aes256GcmBitcode
impl UnwindSafe for Aes256GcmBitcode
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