#[repr(C, align(256))]pub struct ReportMacStruct {
pub report_type: ReportType,
pub _reserved1: [u8; 12],
pub cpusvn: [u8; 16],
pub tee_tcb_info_hash: Sha384Hash,
pub tee_info_hash: Sha384Hash,
pub report_data: [u8; 64],
pub _reserved2: [u8; 32],
pub mac: [u8; 32],
}Expand description
Rust definition of REPORTMACSTRUCT, used by TDX TDREPORT_STRUCT
and the future 256BITSGX
Ref: Intel® Trust Domain CPU Architectural Extensions, table 2-5. Version: 343754-002US, MAY 2021 Link TDX: https://cdrdv2.intel.com/v1/dl/getContent/733582 Link 256BITSGX: https://cdrdv2-public.intel.com/851355/319433-057-architecture-instruction-set-extensions-programming-reference.pdf
Fields§
§report_type: ReportType( 0) TEE Report type
_reserved1: [u8; 12]( 4) Reserved, must be zero
cpusvn: [u8; 16]( 16) Security Version of the CPU
tee_tcb_info_hash: Sha384Hash( 32) SHA384 of TEE_TCB_INFO for TEEs
tee_info_hash: Sha384Hash( 80) SHA384 of TEE_INFO
report_data: [u8; 64](128) Data provided by the user
_reserved2: [u8; 32](192) Reserved, must be zero
mac: [u8; 32](224) The Message Authentication Code over this structure
Implementations§
Source§impl ReportMacStruct
impl ReportMacStruct
Sourcepub fn try_copy_from(src: &[u8]) -> Option<Self>
pub fn try_copy_from(src: &[u8]) -> Option<Self>
If src has the correct length for this type, returns Some<T>
copied from src, else returns None.
Source§impl ReportMacStruct
impl ReportMacStruct
pub const UNPADDED_SIZE: usize = 256
Trait Implementations§
Source§impl AsRef<[u8]> for ReportMacStruct
impl AsRef<[u8]> for ReportMacStruct
Source§impl Clone for ReportMacStruct
impl Clone for ReportMacStruct
Source§fn clone(&self) -> ReportMacStruct
fn clone(&self) -> ReportMacStruct
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ReportMacStruct
impl Debug for ReportMacStruct
Source§impl Default for ReportMacStruct
impl Default for ReportMacStruct
Source§fn default() -> ReportMacStruct
fn default() -> ReportMacStruct
Returns the “default value” for a type. Read more
Source§impl PartialEq for ReportMacStruct
impl PartialEq for ReportMacStruct
impl Eq for ReportMacStruct
Auto Trait Implementations§
impl Freeze for ReportMacStruct
impl RefUnwindSafe for ReportMacStruct
impl Send for ReportMacStruct
impl Sync for ReportMacStruct
impl Unpin for ReportMacStruct
impl UnsafeUnpin for ReportMacStruct
impl UnwindSafe for ReportMacStruct
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