[−][src]Struct loco_protocol::secure::CryptoStore
Stores aes key used on SecureClientStream
Implementations
impl CryptoStore
[src]
pub fn new() -> Result<Self, CryptoError>
[src]
pub fn new_with_key(aes_key: [u8; 16]) -> Self
[src]
Trait Implementations
impl LocoCrypto for CryptoStore
[src]
pub fn encrypt_key<K: HasPublic>(
&self,
key: &Rsa<K>
) -> Result<Vec<u8>, CryptoError>
[src]
&self,
key: &Rsa<K>
) -> Result<Vec<u8>, CryptoError>
pub fn apply_encrypted_key<K: HasPrivate>(
&mut self,
encrypted_aes_key: &[u8],
key: &Rsa<K>
) -> Result<(), CryptoError>
[src]
&mut self,
encrypted_aes_key: &[u8],
key: &Rsa<K>
) -> Result<(), CryptoError>
pub fn encrypt_aes(
&self,
data: &[u8],
iv: &[u8; 16]
) -> Result<Vec<u8>, CryptoError>
[src]
&self,
data: &[u8],
iv: &[u8; 16]
) -> Result<Vec<u8>, CryptoError>
pub fn decrypt_aes(
&self,
data: &[u8],
iv: &[u8; 16]
) -> Result<Vec<u8>, CryptoError>
[src]
&self,
data: &[u8],
iv: &[u8; 16]
) -> Result<Vec<u8>, CryptoError>
pub fn random_iv() -> [u8; 16]
[src]
Auto Trait Implementations
impl RefUnwindSafe for CryptoStore
impl Send for CryptoStore
impl Sync for CryptoStore
impl Unpin for CryptoStore
impl UnwindSafe for CryptoStore
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,