Struct tor_llcrypto::cipher::aes::Aes128Ctr
source · pub struct Aes128Ctr(/* private fields */);
Expand description
AES 128 in counter mode as used by Tor.
Trait Implementations§
source§impl InnerIvInit for Aes128Ctr
impl InnerIvInit for Aes128Ctr
source§fn inner_iv_init(
inner: Self::Inner,
iv: &GenericArray<u8, Self::IvSize>
) -> Self
fn inner_iv_init( inner: Self::Inner, iv: &GenericArray<u8, Self::IvSize> ) -> Self
Initialize value using
inner
and iv
array.source§fn inner_iv_slice_init(
inner: Self::Inner,
iv: &[u8]
) -> Result<Self, InvalidLength>
fn inner_iv_slice_init( inner: Self::Inner, iv: &[u8] ) -> Result<Self, InvalidLength>
Initialize value using
inner
and iv
slice.source§impl IvSizeUser for Aes128Ctr
impl IvSizeUser for Aes128Ctr
source§impl StreamCipher for Aes128Ctr
impl StreamCipher for Aes128Ctr
source§fn try_apply_keystream_inout(
&mut self,
buf: InOutBuf<'_, '_, u8>
) -> Result<(), StreamCipherError>
fn try_apply_keystream_inout( &mut self, buf: InOutBuf<'_, '_, u8> ) -> Result<(), StreamCipherError>
Apply keystream to
inout
data. Read moresource§fn try_apply_keystream(
&mut self,
buf: &mut [u8]
) -> Result<(), StreamCipherError>
fn try_apply_keystream( &mut self, buf: &mut [u8] ) -> Result<(), StreamCipherError>
Apply keystream to data behind
buf
. Read moresource§fn apply_keystream_inout(&mut self, buf: InOutBuf<'_, '_, u8>)
fn apply_keystream_inout(&mut self, buf: InOutBuf<'_, '_, u8>)
Apply keystream to
inout
data. Read moresource§fn apply_keystream(&mut self, buf: &mut [u8])
fn apply_keystream(&mut self, buf: &mut [u8])
Apply keystream to data in-place. Read more
source§fn apply_keystream_b2b(
&mut self,
input: &[u8],
output: &mut [u8]
) -> Result<(), StreamCipherError>
fn apply_keystream_b2b( &mut self, input: &[u8], output: &mut [u8] ) -> Result<(), StreamCipherError>
Apply keystream to data buffer-to-buffer. Read more
Auto Trait Implementations§
impl Freeze for Aes128Ctr
impl RefUnwindSafe for Aes128Ctr
impl Send for Aes128Ctr
impl Sync for Aes128Ctr
impl Unpin for Aes128Ctr
impl UnwindSafe for Aes128Ctr
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
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> KeyIvInit for T
impl<T> KeyIvInit for T
source§fn new(
key: &GenericArray<u8, <T as KeySizeUser>::KeySize>,
iv: &GenericArray<u8, <T as IvSizeUser>::IvSize>
) -> T
fn new( key: &GenericArray<u8, <T as KeySizeUser>::KeySize>, iv: &GenericArray<u8, <T as IvSizeUser>::IvSize> ) -> T
Create new value from fixed length key and nonce.
source§fn new_from_slices(key: &[u8], iv: &[u8]) -> Result<T, InvalidLength>
fn new_from_slices(key: &[u8], iv: &[u8]) -> Result<T, InvalidLength>
Create new value from variable length key and nonce.