Struct rabbit::RabbitCore
source · [−]pub struct RabbitCore { /* private fields */ }
Expand description
Core state of the Rabbit stream cipher initialized with key and IV.
Trait Implementations
sourceimpl BlockSizeUser for RabbitCore
impl BlockSizeUser for RabbitCore
sourcefn block_size() -> usize
fn block_size() -> usize
Return block size in bytes.
sourceimpl Clone for RabbitCore
impl Clone for RabbitCore
sourcefn clone(&self) -> RabbitCore
fn clone(&self) -> RabbitCore
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl InnerIvInit for RabbitCore
impl InnerIvInit for RabbitCore
sourcefn inner_iv_init(inner: RabbitKeyOnlyCore, iv: &Iv) -> Self
fn inner_iv_init(inner: RabbitKeyOnlyCore, iv: &Iv) -> Self
Initialize value using inner
and iv
array.
sourcefn 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.
sourceimpl InnerUser for RabbitCore
impl InnerUser for RabbitCore
type Inner = RabbitKeyOnlyCore
type Inner = RabbitKeyOnlyCore
Inner type.
sourceimpl IvSizeUser for RabbitCore
impl IvSizeUser for RabbitCore
sourceimpl StreamCipherCore for RabbitCore
impl StreamCipherCore for RabbitCore
sourcefn remaining_blocks(&self) -> Option<usize>
fn remaining_blocks(&self) -> Option<usize>
Return number of remaining blocks before cipher wraps around. Read more
sourcefn process_with_backend(
&mut self,
f: impl StreamClosure<BlockSize = Self::BlockSize>
)
fn process_with_backend(
&mut self,
f: impl StreamClosure<BlockSize = Self::BlockSize>
)
Process data using backend provided to the rank-2 closure.
sourcefn write_keystream_block(
&mut self,
block: &mut GenericArray<u8, Self::BlockSize>
)
fn write_keystream_block(
&mut self,
block: &mut GenericArray<u8, Self::BlockSize>
)
Write keystream block. Read more
sourcefn write_keystream_blocks(
&mut self,
blocks: &mut [GenericArray<u8, Self::BlockSize>]
)
fn write_keystream_blocks(
&mut self,
blocks: &mut [GenericArray<u8, Self::BlockSize>]
)
Write keystream blocks. Read more
sourcefn apply_keystream_block_inout(
&mut self,
block: InOut<'_, '_, GenericArray<u8, Self::BlockSize>>
)
fn apply_keystream_block_inout(
&mut self,
block: InOut<'_, '_, GenericArray<u8, Self::BlockSize>>
)
Apply keystream block. Read more
sourcefn apply_keystream_blocks(
&mut self,
blocks: &mut [GenericArray<u8, Self::BlockSize>]
)
fn apply_keystream_blocks(
&mut self,
blocks: &mut [GenericArray<u8, Self::BlockSize>]
)
Apply keystream blocks. Read more
sourcefn apply_keystream_blocks_inout(
&mut self,
blocks: InOutBuf<'_, '_, GenericArray<u8, Self::BlockSize>>
)
fn apply_keystream_blocks_inout(
&mut self,
blocks: InOutBuf<'_, '_, GenericArray<u8, Self::BlockSize>>
)
Apply keystream blocks. Read more
sourcefn try_apply_keystream_partial(
self,
buf: InOutBuf<'_, '_, u8>
) -> Result<(), StreamCipherError>
fn try_apply_keystream_partial(
self,
buf: InOutBuf<'_, '_, u8>
) -> Result<(), StreamCipherError>
Try to apply keystream to data not divided into blocks. Read more
sourcefn apply_keystream_partial(self, buf: InOutBuf<'_, '_, u8>)
fn apply_keystream_partial(self, buf: InOutBuf<'_, '_, u8>)
Try to apply keystream to data not divided into blocks. Read more
impl ZeroizeOnDrop for RabbitCore
zeroize
only.Auto Trait Implementations
impl RefUnwindSafe for RabbitCore
impl Send for RabbitCore
impl Sync for RabbitCore
impl Unpin for RabbitCore
impl UnwindSafe for RabbitCore
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more