pub type SecretKey = HeapByteArray<CRYPTO_BOX_SECRETKEYBYTES>;
Available on crate feature
nightly
only.Expand description
Heap-allocated, page-aligned secret key for authenticated public-key boxes, for use with protected memory.
Aliased Type§
struct SecretKey(/* private fields */);
Trait Implementations
source§impl<const LENGTH: usize> ByteArray<LENGTH> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> ByteArray<LENGTH> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Bytes for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Bytes for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Clone for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Clone for HeapByteArray<LENGTH>
source§fn clone(&self) -> HeapByteArray<LENGTH>
fn clone(&self) -> HeapByteArray<LENGTH>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<const LENGTH: usize> Debug for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Debug for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Default for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Default for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> DerefMut for HeapByteArray<LENGTH>
impl<const LENGTH: usize> DerefMut for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Drop for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Drop for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> From<StackByteArray<LENGTH>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> From<StackByteArray<LENGTH>> for HeapByteArray<LENGTH>
source§fn from(other: StackByteArray<LENGTH>) -> Self
fn from(other: StackByteArray<LENGTH>) -> Self
Converts to this type from the input type.
source§impl<const LENGTH: usize> Index<RangeInclusive<usize>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Index<RangeInclusive<usize>> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Index<RangeToInclusive<usize>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Index<RangeToInclusive<usize>> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> IndexMut<RangeInclusive<usize>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> IndexMut<RangeInclusive<usize>> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> IndexMut<RangeToInclusive<usize>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> IndexMut<RangeToInclusive<usize>> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> Lockable<HeapByteArray<LENGTH>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> Lockable<HeapByteArray<LENGTH>> for HeapByteArray<LENGTH>
source§fn mlock(
self
) -> Result<Protected<HeapByteArray<LENGTH>, ReadWrite, Locked>, Error>
fn mlock( self ) -> Result<Protected<HeapByteArray<LENGTH>, ReadWrite, Locked>, Error>
Locks a HeapByteArray, and returns a Protected wrapper.
source§impl<const LENGTH: usize> MutByteArray<LENGTH> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> MutByteArray<LENGTH> for HeapByteArray<LENGTH>
source§fn as_mut_array(&mut self) -> &mut [u8; LENGTH]
fn as_mut_array(&mut self) -> &mut [u8; LENGTH]
Returns a mutable reference to the underlying fixed-length byte array.
source§impl<const LENGTH: usize> MutBytes for HeapByteArray<LENGTH>
impl<const LENGTH: usize> MutBytes for HeapByteArray<LENGTH>
source§fn as_mut_slice(&mut self) -> &mut [u8] ⓘ
fn as_mut_slice(&mut self) -> &mut [u8] ⓘ
Returns a mutable slice to the underlying bytes.
source§fn copy_from_slice(&mut self, other: &[u8])
fn copy_from_slice(&mut self, other: &[u8])
Copies into the underlying slice from
other
. Panics if lengths do not
match.source§impl<const LENGTH: usize> NewByteArray<LENGTH> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> NewByteArray<LENGTH> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> NewBytes for HeapByteArray<LENGTH>
impl<const LENGTH: usize> NewBytes for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> NewLockedFromSlice<HeapByteArray<LENGTH>> for HeapByteArray<LENGTH>
impl<const LENGTH: usize> NewLockedFromSlice<HeapByteArray<LENGTH>> for HeapByteArray<LENGTH>
source§impl<const LENGTH: usize> PartialEq for HeapByteArray<LENGTH>
impl<const LENGTH: usize> PartialEq for HeapByteArray<LENGTH>
source§fn eq(&self, other: &HeapByteArray<LENGTH>) -> bool
fn eq(&self, other: &HeapByteArray<LENGTH>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.