pub fn unlock(&mut self, pin: &[u8], mgm_key: &[u8]) -> Result<()> {
        self.yk.verify_pin(pin)?;

        match MgmKey::from_bytes(mgm_key) {
            Ok(mgm) => self.yk.authenticate(mgm)?,
            Err(_) => return Err(Error::InvalidManagementKey),
        };
        Ok(())
    }
/// Unlock the yubikey for signing or provisioning operations
Unlock the yubikey for signing or provisioning operations
Unlock the yubikey for signing or provisioning operations
pub fn unlock(&mut self, pin: &[u8], mgm_key: &[u8]) -> Result<()> {
        self.yk.verify_pin(pin)?;
        match MgmKey::from_bytes(mgm_key) {
            Ok(mgm) => self.yk.authenticate(mgm)?,
            Err(_) => return Err(Error::InvalidManagementKey),
        };
        Ok(())
    }
pub fn unlock ( & mut self , pin : & [ u8 ] , mgm_key : & [ u8 ] ) -> Result < ( ) > { self . yk . verify_pin ( pin ) ? ; match MgmKey :: from_bytes ( mgm_key ) { Ok ( mgm ) => self . yk . authenticate ( mgm ) ? , Err ( _ ) => return Err ( Error :: InvalidManagementKey ) , } ; Ok ( ( ) ) }
Unlock the yubikey for signing or provisioning operations
Unlock the yubikey for signing or provisioning operations
&mut self
pin
&[u8]
mgm_key
&[u8]