pub struct ItemKeyRecord {Show 27 fields
pub key_class: u32,
pub print_name: Vec<u8>,
pub alias: Vec<u8>,
pub permanent: bool,
pub private: bool,
pub modifiable: bool,
pub label: [u8; 20],
pub application_tag: Vec<u8>,
pub key_creator: Vec<u8>,
pub key_type: u32,
pub key_size_in_bits: u32,
pub effective_key_size: u32,
pub start_date: Vec<u8>,
pub end_date: Vec<u8>,
pub sensitive: bool,
pub always_sensitive: bool,
pub extractable: bool,
pub never_extractable: bool,
pub encrypt: bool,
pub decrypt: bool,
pub derive: bool,
pub sign: bool,
pub verify: bool,
pub sign_recover: bool,
pub verify_recover: bool,
pub wrap: bool,
pub unwrap: bool,
}Expand description
The attribute set of the symmetric key that protects one item.
Every field here holds the value macOS writes for an item key. Two are worth pointing out because they look wrong:
key_classis17, the symmetric-key relation id, not aCSSM_KEYCLASSconstant.print_nameis the 20-bytessgplabel rather than a readable name.
Fields§
§key_class: u32§print_name: Vec<u8>§alias: Vec<u8>§permanent: bool§private: bool§modifiable: bool§label: [u8; 20]The label shared with the item’s ssgp payload; how the two are linked.
application_tag: Vec<u8>§key_creator: Vec<u8>The CSP that created the key, as a braced GUID string with a terminator.
key_type: u32CSSM_ALGID_3DES_3KEY_EDE.
key_size_in_bits: u32§effective_key_size: u32§start_date: Vec<u8>Eight zero bytes for “unset”, stored as a blob rather than a date.
end_date: Vec<u8>§sensitive: bool§always_sensitive: bool§extractable: bool§never_extractable: bool§encrypt: bool§decrypt: bool§derive: bool§sign: bool§verify: bool§sign_recover: bool§verify_recover: bool§wrap: bool§unwrap: boolImplementations§
Source§impl ItemKeyRecord
impl ItemKeyRecord
Sourcepub fn for_item_key(label: [u8; 20]) -> Self
pub fn for_item_key(label: [u8; 20]) -> Self
The record macOS writes for the key of a password item.
Trait Implementations§
Source§impl Clone for ItemKeyRecord
impl Clone for ItemKeyRecord
Source§fn clone(&self) -> ItemKeyRecord
fn clone(&self) -> ItemKeyRecord
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ItemKeyRecord
impl RefUnwindSafe for ItemKeyRecord
impl Send for ItemKeyRecord
impl Sync for ItemKeyRecord
impl Unpin for ItemKeyRecord
impl UnsafeUnpin for ItemKeyRecord
impl UnwindSafe for ItemKeyRecord
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more