Struct optee_utee::crypto_op::OperationInfo
source · pub struct OperationInfo { /* private fields */ }Expand description
Represent the information about a crypto information.
Implementations§
source§impl OperationInfo
impl OperationInfo
sourcepub fn from_raw(raw: TEE_OperationInfo) -> Self
pub fn from_raw(raw: TEE_OperationInfo) -> Self
Return the OperationInfo struct based on the raw struct TEE_OperationInfo.
The raw structure contains following fields:
algorithm: One of the algorithm of AlgorithmId.mode: One of the mode of OperationMode.maxKeySize: The maximum key sizes of different algorithms as defined in TransientObjectType.operationClass: One of the constants from OperationConstant.keySize: 5.1) For an operation that makes no use of keys, 0. 5.2) For an operation that uses a single key, the actual size of this key. 5.3) For an operation that uses multiple keys, 0. (The actual value ofkeySizecan be obtained from OperationInfoMultiple).requiredKeyUsage: 6.1) For an operation that makes no use of keys, 0. 6.2) For an operation that uses a single key, a bit vector that describes the necessary bits in the object usage forset_keyfunctions to succeed without panicking. 6.3) For an operation that uses multiple keys, 0. (The actual value ofrequiredKeyUsagecan be obtained from OperationInfoMultiple.digestLength: For a Mac, AE, or Digest, describes the number of bytes in the digest or tag.handleState: A bit vector describing the current state of the operation. Contains one or more of the HandleFlag.
sourcepub fn max_key_size(&self) -> u32
pub fn max_key_size(&self) -> u32
Return the maxDataSize field of the raw structure TEE_OperationInfo.
Auto Trait Implementations§
impl Freeze for OperationInfo
impl RefUnwindSafe for OperationInfo
impl Send for OperationInfo
impl Sync for OperationInfo
impl Unpin for OperationInfo
impl UnwindSafe for OperationInfo
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