DstackTdxPolicy configures Intel TDX attestation verification for Dstack-based TEE deployments.
Configuration fields
Runtime verification fields
These fields are required by default for production security:Expected bootchain measurements (MRTD and RTMR0-2). Required unless
disable_runtime_verification is true.SHA256 hash of the Dstack image’s
sha256sum.txt file. Required unless disable_runtime_verification is true. Must be lowercase hex.Expected application configuration. Required unless
disable_runtime_verification is true. The verifier computes the hash of this JSON value and compares it against the hash in the event log.TCB verification fields
List of acceptable TCB (Trusted Computing Base) status values. See TCB status values for details.Valid values:
UpToDate, SWHardeningNeeded, ConfigurationNeeded, OutOfDate, RevokedGrace period in seconds for
OutOfDate TCB status. Only applies when OutOfDate is in allowed_tcb_status.- A value of
0means no grace window - If set, platforms with
OutOfDatestatus are accepted only iftcb_date + grace_period >= current_time - Requires
OutOfDateinallowed_tcb_statusor configuration will fail
Optional verification settings
Skip bootchain, app_compose, and os_image_hash verification. Not recommended for production.When
true, the runtime verification fields become optional. DstackTdxPolicy::dev() sets this to true.Intel PCCS (Provisioning Certificate Caching Service) URL for fetching attestation collateral. Defaults to Phala’s public PCCS.
Cache Intel collateral to avoid repeated network fetches. When enabled, collateral is cached per verification session.
Examples
Development policy
Relaxed verification for testing:Production policy with strict TCB
Only accept fully patched platforms:Production policy with grace period
AcceptOutOfDate platforms within a 30-day grace period:
Validation rules
The policy performs validation before creating a verifier:- TCB status values - All values in
allowed_tcb_statusmust be valid TCB status strings - Hex strings - All measurement hashes must be lowercase hexadecimal
- Grace period - If
grace_periodis set,allowed_tcb_statusmust includeOutOfDate - Runtime fields - If
disable_runtime_verificationis false (default), all runtime fields are required:expected_bootchainmust be providedos_image_hashmust be providedapp_composemust be provided
Example validation errors
Related
TCB status values
Understanding TCB security levels
Computing measurements
Generate bootchain measurements