Skip to main content

Crate product_policy

Crate product_policy 

Source
Expand description

Measured product policy: enum, per-VM value, codec.

To add a product: define its body in a sibling module, with the vpci_relay field that the device policy sets, then add one N => Variant(body::Body), line to define_product_policy! below. N is a mesh wire tag and must never be reused.

Re-exports§

pub use uefi_security_policy::UefiSecurityPolicy;

Modules§

azure
Azure policy body.
cwcow
Cwcow policy body and validation methods.
product_policy_helpers
Shared helpers for product policy validation and serialization. Shared helpers for product policy validation and serialization.
sivm
Sivm policy body and validation methods. Sivm policy body and validation methods. Accessor MeasuredProductPolicy::sivm is generated by define_product_policy! in lib.rs.
uefi_security_policy
UEFI enforced security settings. Shared validation for the currently enforced UEFI product-policy checks (secure-boot-required), used by product policy variants (Sivm, Cwcow, etc.).

Structs§

AllowedPciDevice
A PCI device that OpenHCL’s VPCI relay may expose to VTL0: one with every ID that is set.
MeasuredProductPolicy
Per-VM measured product policy.
VpciRelayPolicy
The VPCI relay settings from the manifest’s device policy file.

Enums§

ProductPolicy
Measured product policy. Mesh tags are part of the wire format and must never be reused.
ProductPolicyDecodeError
Errors from decode_product_policy.
VpciRelayMode
When OpenHCL runs the VPCI relay. OPENHCL_ENABLE_VPCI_RELAY can override the defaults, but not Self::MustBeOn.

Constants§

PRODUCT_POLICY_PATH
Absolute path of the measured product policy file in the OpenHCL initrd.

Functions§

decode_product_policy
Decode mesh_protobuf bytes. Caller must skip empty payloads (which signal “no policy installed”) before calling.
encode_product_policy
Encode a policy as mesh_protobuf bytes for the IGVM payload.