[][src]Struct libcryptsetup_rs::CryptActivation

pub struct CryptActivation<'a> { /* fields omitted */ }

Handle for activation options

Implementations

impl<'a> CryptActivation<'a>[src]

pub fn activate_by_passphrase(
    &mut self,
    name: Option<&str>,
    keyslot: Option<c_uint>,
    passphrase: &[u8],
    flags: CryptActivateFlags
) -> Result<c_uint, LibcryptErr>
[src]

Activate device by passphrase.

A value of None for the name will only check the passphrase and will not activate the keyslot.

pub fn activate_by_keyfile_device_offset(
    &mut self,
    name: Option<&str>,
    keyslot: Option<c_uint>,
    keyfile: &Path,
    keyfile_size: Option<size_t>,
    keyfile_offset: u64,
    flags: CryptActivateFlags
) -> Result<c_uint, LibcryptErr>
[src]

Activate device by key file

pub fn activate_by_volume_key(
    &mut self,
    name: Option<&str>,
    volume_key: Option<&[u8]>,
    flags: CryptActivateFlags
) -> Result<(), LibcryptErr>
[src]

Activate device by volume key

pub fn activate_by_keyring(
    &mut self,
    name: Option<&str>,
    key_description: &str,
    keyslot: Option<c_uint>,
    flags: CryptActivateFlags
) -> Result<c_uint, LibcryptErr>
[src]

Activeate device using passphrase in kernel keyring

pub fn deactivate(
    &mut self,
    name: &str,
    flags: CryptDeactivateFlags
) -> Result<(), LibcryptErr>
[src]

Deactivate crypt device

Auto Trait Implementations

impl<'a> RefUnwindSafe for CryptActivation<'a>

impl<'a> !Send for CryptActivation<'a>

impl<'a> !Sync for CryptActivation<'a>

impl<'a> Unpin for CryptActivation<'a>

impl<'a> !UnwindSafe for CryptActivation<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.