[−][src]Struct chacha20::ChaCha20
The ChaCha20 stream cipher (RFC 8439 version with 96-bit nonce)
Use ChaCha20Legacy
for the legacy (a.k.a. "djb") construction with a
64-bit nonce.
Trait Implementations
impl NewStreamCipher for ChaCha20
[src]
type KeySize = U32
Key size in bytes
type NonceSize = U12
Nonce size in bytes
fn new(
key: &GenericArray<u8, Self::KeySize>,
iv: &GenericArray<u8, Self::NonceSize>
) -> Self
[src]
key: &GenericArray<u8, Self::KeySize>,
iv: &GenericArray<u8, Self::NonceSize>
) -> Self
fn new_var(key: &[u8], nonce: &[u8]) -> Result<Self, InvalidKeyNonceLength>
[src]
impl SyncStreamCipher for ChaCha20
[src]
fn try_apply_keystream(&mut self, data: &mut [u8]) -> Result<(), LoopError>
[src]
fn apply_keystream(&mut self, data: &mut [u8])
[src]
impl SyncStreamCipherSeek for ChaCha20
[src]
fn current_pos(&self) -> u64
[src]
fn seek(&mut self, pos: u64)
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
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.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<C> StreamCipher for C where
C: SyncStreamCipher,
[src]
C: SyncStreamCipher,
impl<T> Same<T> for T
type Output = T
Should always be Self