Skip to content

dcap-qvl is_valid() accepts non-UpToDate statuses #125

@pbeza

Description

@pbeza

The TcbStatus::is_valid() method in dcap-qvl/src/tcb_info.rs returns true for all statuses except Revoked, meaning consumers who rely solely on this built-in check may unknowingly accept quotes with known vulnerabilities (e.g. OutOfDate, ConfigurationNeeded).

Root Cause

dcap-qvl's TcbStatus::is_valid() returns true for all statuses except Revoked:

pub(crate) fn is_valid(&self) -> bool {
    match self {
        Self::UpToDate => true,
        Self::SWHardeningNeeded => true,
        Self::ConfigurationNeeded => true,
        Self::ConfigurationAndSWHardeningNeeded => true,
        Self::OutOfDate => true,
        Self::OutOfDateConfigurationNeeded => true,
        Self::Revoked => false,
    }
}

This is used as the internal gate at verify.rs:666. The caller fully mitigates this by requiring status == "UpToDate" and empty advisory IDs in the caller's attestation layer.

Attack Path

None for callers who check status independently — mitigated.

Impact

None for callers who check status independently. Other dcap-qvl consumers who rely solely on its built-in is_valid() may unknowingly accept quotes with known vulnerabilities.

Suggested Fix

No action needed for callers who check status independently. Consider having dcap-qvl default to stricter validation or clearly document that callers must check the status string themselves.


Note: This issue was created automatically. The vulnerability report was generated by Claude and has not been verified by a human.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions