Skip to main content

SivmPolicy

Struct SivmPolicy 

Source
pub struct SivmPolicy {
    pub require_ephemeral_vmgs: bool,
    pub require_secure_boot: bool,
    pub require_secure_boot_vars: bool,
    pub require_bcd_integrity: bool,
    pub custom_uefi_json: Vec<u8>,
}
Expand description

Sivm policy body.

Fields§

§require_ephemeral_vmgs: bool

Reserved: require an ephemeral VMGS. Not enforced at runtime yet.

§require_secure_boot: bool

Require secure boot is enabled.

§require_secure_boot_vars: bool

Reserved: require PK/KEK/db/dbx variables. Not enforced at runtime yet.

§require_bcd_integrity: bool

Reserved: require BootConfigurationDataHash. Not enforced at runtime yet.

§custom_uefi_json: Vec<u8>

Custom UEFI JSON bytes (base64 in manifest JSON). Required in manifests and asserted non-empty at build time when secure boot plus secure-boot-vars or BCD-integrity are set;

Trait Implementations§

Source§

impl Clone for SivmPolicy

Source§

fn clone(&self) -> SivmPolicy

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for SivmPolicy

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for SivmPolicy

Source§

fn default() -> SivmPolicy

Returns the “default value” for a type. Read more
Source§

impl DefaultEncoding for SivmPolicy

Source§

type Encoding = TableEncoder

The encoding to use for the serialization. Read more
Source§

impl DescribeTable for SivmPolicy

Source§

const DESCRIPTION: MessageDescription<'static>

The protobuf message description for this type.
Source§

impl<'de> Deserialize<'de> for SivmPolicy

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for SivmPolicy

Source§

fn eq(&self, other: &SivmPolicy) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for SivmPolicy

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'encoding, AnyR: 'static> StructDecodeMetadata<'encoding, AnyR> for SivmPolicy

Source§

const DECODERS: &'static [ErasedDecoderEntry]

The list of decoder vtables.
Source§

impl<AnyR: 'static> StructEncodeMetadata<AnyR> for SivmPolicy

Source§

const ENCODERS: &'static [ErasedEncoderEntry]

The list of encoder vtables.
Source§

impl StructMetadata for SivmPolicy

Source§

const NUMBERS: &'static [u32]

The field numbers for each field.
Source§

const OFFSETS: &'static [usize]

The byte offset to each field within the struct.
Source§

impl UefiSecurityPolicy for SivmPolicy

Source§

fn validate_secure_boot_enabled(&self, on: bool) -> Result<()>

Validate that secure boot is enabled if required by the policy.
Source§

impl StructuralPartialEq for SivmPolicy

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> DescribedProtobuf for T
where T: DefaultEncoding + Protobuf, <T as DefaultEncoding>::Encoding: DescribeMessage<T>,

§

const DESCRIPTION: MessageDescription<'static>

The message description.
§

const TYPE_URL: TypeUrl<'static> = _

The type URL for this message.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Protobuf for T
where T: DefaultEncoding, <T as DefaultEncoding>::Encoding: MessageEncode<T, NoResources> + for<'a> MessageDecode<'a, T, NoResources> + FieldEncode<T, NoResources> + for<'a> FieldDecode<'a, T, NoResources>,

§

type Encoding = <T as DefaultEncoding>::Encoding

The default encoding for Self.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,