[−][src]Struct yubihsm::wrap::Key
Wrap key to import into the device
Methods
impl Key
[src]
pub fn generate_random(key_id: Id, algorithm: Algorithm) -> Self
[src]
Generate a random wrap key with the given key size.
pub fn from_bytes(key_id: Id, bytes: &[u8]) -> Result<Self, DeviceError>
[src]
Create a new wrap::Key
instance. Must be 16, 24, or 32-bytes long.
pub fn label(self, label: Label) -> Self
[src]
Set the object label on this key
pub fn domains(self, domains: Domain) -> Self
[src]
Set the domains this wrap key can be used in (default: all)
pub fn capabilities(self, capabilities: Capability) -> Self
[src]
Set the capabilities of this key (what it can be used for)
pub fn delegated_capabilities(self, capabilities: Capability) -> Self
[src]
Set the delegated capabilities of this key (what capabilities it can set on imported objects)
pub fn create(&self, client: &mut Client) -> Result<(), ClientError>
[src]
Create this key within the HSM
Trait Implementations
impl Clone for Key
[src]
fn clone(&self) -> Key
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Drop for Key
[src]
impl Debug for Key
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)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> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Same for T
type Output = T
Should always be Self