pub struct CipherCtx(/* private fields */);Methods from Deref<Target = CipherCtxRef>§
Sourcepub fn init_encrypt(
&mut self,
cipher: &Cipher,
key: &[u8],
iv: &[u8; 16],
) -> Result<(), ErrorStack>
pub fn init_encrypt( &mut self, cipher: &Cipher, key: &[u8], iv: &[u8; 16], ) -> Result<(), ErrorStack>
Configures CipherCtx for a fresh encryption operation using cipher.
This corresponds to EVP_EncryptInit_ex.
Sourcepub fn init_decrypt(
&mut self,
cipher: &Cipher,
key: &[u8],
iv: &[u8; 16],
) -> Result<(), ErrorStack>
pub fn init_decrypt( &mut self, cipher: &Cipher, key: &[u8], iv: &[u8; 16], ) -> Result<(), ErrorStack>
Configures CipherCtx for a fresh decryption operation using cipher.
This corresponds to EVP_DecryptInit_ex.
Trait Implementations§
Source§impl AsMut<CipherCtxRef> for CipherCtx
impl AsMut<CipherCtxRef> for CipherCtx
Source§fn as_mut(&mut self) -> &mut CipherCtxRef
fn as_mut(&mut self) -> &mut CipherCtxRef
Converts this type into a mutable reference of the (usually inferred) input type.
Source§impl AsRef<CipherCtxRef> for CipherCtx
impl AsRef<CipherCtxRef> for CipherCtx
Source§fn as_ref(&self) -> &CipherCtxRef
fn as_ref(&self) -> &CipherCtxRef
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Borrow<CipherCtxRef> for CipherCtx
impl Borrow<CipherCtxRef> for CipherCtx
Source§fn borrow(&self) -> &CipherCtxRef
fn borrow(&self) -> &CipherCtxRef
Immutably borrows from an owned value. Read more
Source§impl BorrowMut<CipherCtxRef> for CipherCtx
impl BorrowMut<CipherCtxRef> for CipherCtx
Source§fn borrow_mut(&mut self) -> &mut CipherCtxRef
fn borrow_mut(&mut self) -> &mut CipherCtxRef
Mutably borrows from an owned value. Read more
Source§impl Deref for CipherCtx
impl Deref for CipherCtx
Source§type Target = CipherCtxRef
type Target = CipherCtxRef
The resulting type after dereferencing.
Source§fn deref(&self) -> &CipherCtxRef
fn deref(&self) -> &CipherCtxRef
Dereferences the value.
Source§impl DerefMut for CipherCtx
impl DerefMut for CipherCtx
Source§fn deref_mut(&mut self) -> &mut CipherCtxRef
fn deref_mut(&mut self) -> &mut CipherCtxRef
Mutably dereferences the value.
Source§impl ForeignType for CipherCtx
impl ForeignType for CipherCtx
Source§type CType = evp_cipher_ctx_st
type CType = evp_cipher_ctx_st
The raw C type.
Source§type Ref = CipherCtxRef
type Ref = CipherCtxRef
The type representing a reference to this type.
Source§unsafe fn from_ptr(ptr: *mut EVP_CIPHER_CTX) -> CipherCtx
unsafe fn from_ptr(ptr: *mut EVP_CIPHER_CTX) -> CipherCtx
Constructs an instance of this type from its raw type. Read more
Source§fn as_ptr(&self) -> *mut EVP_CIPHER_CTX
fn as_ptr(&self) -> *mut EVP_CIPHER_CTX
Returns a raw pointer to the wrapped value.
impl Send for CipherCtx
impl Sync for CipherCtx
Auto Trait Implementations§
impl Freeze for CipherCtx
impl RefUnwindSafe for CipherCtx
impl Unpin for CipherCtx
impl UnsafeUnpin for CipherCtx
impl UnwindSafe for CipherCtx
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