vciy
Remediation & CI · For Remediation Owners · 2026-11-26

Governing .trivyignore and .grype.yaml with Digest-Pinned OpenVEX and OASIS CSAF 2.0 Feeds

Put CVE-2025-55182 (Meta CNA 10.0, cvss_nvd = null, kev_listed = true, due 2025-12-12) or CVE-2024-21626 (8.6, opencontainers runc) into .trivyignore without an expired_at date or image digest, and every later container build inherits that clearance unchecked.

Trivy's plain-text .trivyignore keys on bare CVE strings across the whole repository, so a dependency graph change in package-lock.json or a base-image tag bump never invalidates the prior not_affected premise.

Primary corpus receipts · frozen evidence
CVE-2025-55182 · CISA KEV due date and CNA 10.0 vs null NVD primary CVSS
kev_listed=true, added=2025-12-05, due=2025-12-12, ransomware=known | Meta CNA: 10.0 (CWE-502, react-server-dom-webpack) | NVD CVSS: null | EPSS: 0.99802as of 2026-09-04 · CISA KEV / Meta CNA / NIST NVD / FIRST EPSS
CVE-2024-21626 · Container runtime CWE-403 descriptor scope without KEV listing
kev_listed=false | GitHub CNA + NIST NVD: 8.6 (CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H, CWE-403) | opencontainers runc | EPSS: 0.18923as of 2026-09-29 · GitHub CNA / NIST NVD / FIRST EPSS

How repo-wide CVE strings survive container digest and dependency shifts

Inspect what trivy image --ignorefile .trivyignore and grype -c .grype.yaml actually match at build time. Unless constrained by package PURL, OCI image digest (sha256:...), and expired_at timestamp, a suppression entry matches the CVE identifier globally across every stage of a multi-stage Dockerfile.

Trace that behavior on CVE-2025-55182 in a Node monorepo. On day 1, image digest sha256:4a8e...19c0 bundles static react-dom assets only, while react-server-dom-webpack sits in workspace devDependencies (cvss_nvd = null, Meta CNA = 10.0, EPSS = 0.99802). An engineer adds CVE-2025-55182 to .trivyignore so the release pipeline passes. Two sprints later, commit b71d902 enables server-rendered routes in next.config.mjs, pulling pkg:npm/react-server-dom-webpack into the production runtime layer (sha256:9f2c...88d4) while CISA KEV carries due_date = 2025-12-12 (ransomware = known). Because .trivyignore keyed on the bare CVE ID rather than the runtime package set and review window, CI reports zero findings on an exposed production image.

A parallel drift hits CVE-2024-21626 (opencontainers runc, CWE-403, 8.6, EPSS 0.18923, kev_listed = false). A platform team records not_affected in .grype.yaml because CI runners pin runc >= 1.1.12 and forbid untrusted WORKDIR metadata, yet downstream self-hosted runners on an older host node reuse the same repository config without re-evaluating host runtime versions. Stamping an inspection sticker on a shipping container's serial plate and swapping the cargo inside defeats the seal.

Suppressions bound only to a CVE string outlive the artifact that earned them.

Projecting .trivyignore.yaml, .grype.yaml, OpenVEX, and CSAF 2.0 from one chain

Across public-sector DevSecOps pipelines and national CSIRTs, four tools demand four distinct schemas for the same triage call: Trivy parses structured .trivyignore.yaml (vulnerabilities[].expired_at), Grype parses .grype.yaml (ignore[].vulnerability plus package.name), container registries consume OpenVEX v0.2.0 (statements[]), and European CSIRTs alongside EU Cyber Resilience Act Article 14(8) workflows validate OASIS CSAF 2.0 (document.category = "csaf_vex", product_status.known_not_affected).

Maintaining those four artifacts by hand guarantees divergence: .grype.yaml drops the expired_at date, .trivyignore omits the human reviewer, and third-party CSAF feeds (publisher.name = "Coordinator") lack internal sign-off.

Driving all four files from a single hash-chained decision record via GET /api/v1/suppressions?format=trivy|grype|openvex|csaf enforces two deterministic gates on every build. First, any record whose review_by date is earlier than today's UTC date is withheld from .trivyignore.yaml and .grype.yaml (# WITHHELD) and downgraded to under_investigation in OpenVEX and CSAF product_status. Second, any not_affected verdict whose CVE appears in CISA KEV (CVE-2025-55182) or enters KEV after the frozen snapshot (!frozen.kev.listed && live.kev.listed) is withheld immediately so the scanner fails closed.

Keep one dated record in the vault; compile scanner configs at build time.

FAIL-CLOSED SUPPRESSION PIPELINE: VAULT TO TRIVY, GRYPE AND CSAF 2.01. ATTRIBUTED RECORDCVE-2024-21626 not_affectedPURL + review_by 2027-03-01CVE-2025-55182 KEV due 12-12Named engineer + tsServerSHA-256 frozen KEV + EPSS2. BUILD-TIME GATEVerify review_by >= today UTCWithhold not_affected on KEVCatch runtime PURL additionsDrop stale ignores (# WITHHELD)GET /api/v1/suppressions3. DETERMINISTIC OUTPUTS.trivyignore.yaml (expired_at).grype.yaml (reason + proof)OpenVEX v0.2.0 + CDX 1.6 VEXOASIS CSAF 2.0 csaf_vexunder_investigation on expiryFAIL-CLOSED RULE:Any expired review_by or KEV conflict is omitted from active scannerignores and set to under_investigation in OpenVEX and CSAF 2.0 exports.
Compiling Trivy, Grype, OpenVEX, CycloneDX VEX, and OASIS CSAF 2.0 outputs from dated decision records.

The three-command CI verification loop

Step 1: validate inbound CycloneDX VEX, OpenVEX v0.2.0, or OASIS CSAF 2.0 advisories with curl -sSf "https://app.vciy.com/api/v1/vex?fail_on=kev_conflict,missing_author" -H "Authorization: Bearer $VCIY_KEY" --data-binary @advisory.csaf.json (or inspect interactively at [/app/vex-import](https://app.vciy.com/app/vex-import)). Missing human signers or KEV not_affected contradictions return HTTP 422 gate_failed.

Step 2: mint the component-scoped decision record (POST /api/v1/records) naming the exact PURL (pkg:npm/react-dom without react-server-dom-webpack, or runc host constraint on CVE-2024-21626) and a bounded review_by date.

Step 3: fetch .trivyignore.yaml or .grype.yaml from /api/v1/suppressions before invoking the scanner, and enforce schema, expiry, digest/proof linkage, and SHA-256 receipt integrity with the standalone Rust binary below (rustc --edition 2021 verify_suppressions.rs -o verify_suppressions && ./verify_suppressions).

Gate inbound VEX, bind the PURL and review date, verify before scan.

Where surface signals mislead.

Each triplet separates the shortcut a naive rule takes from the mechanism underneath and the call you can defend to an auditor.

Bare CVE in .trivyignore on CVE-2025-55182 (CNA 10.0, NVD null, KEV due 2025-12-12)

Surface signal: Ignoring CVE-2025-55182 in .trivyignore while react-server-dom-webpack is unused in a static build stays safe across later commits.

Actual mechanism: Enabling Server Actions in a later commit adds pkg:npm/react-server-dom-webpack to the runtime image (sha256:9f2c...) while the timeless CVE rule keeps Trivy silent on an active ransomware KEV.

Defensible call: Emit .trivyignore.yaml from /api/v1/suppressions?format=trivy so KEV conflicts are withheld and expired_at forces periodic re-verification.

Repo-local .grype.yaml on CVE-2024-21626 (runc CWE-403, 8.6, EPSS 18.92%)

Surface signal: Committing a .grype.yaml ignore entry documents the runc >= 1.1.12 host mitigation for central registry scanners and auditors.

Actual mechanism: Registry-level Trivy/Grype jobs and downstream adopters never read repo-local .grype.yaml comments, and self-hosted runner pools can drift onto older runc builds.

Defensible call: Bind the CVE-2024-21626 record to a review_by date and export both .grype.yaml for CI and OpenVEX/CSAF 2.0 for registry consumers.

Coordinator-authored OASIS CSAF 2.0 VEX (document.category = csaf_vex)

Surface signal: Feeding an upstream csaf_vex JSON advisory straight into --vex proves internal engineering review for CRA Article 14 audits.

Actual mechanism: Generic coordinator publisher names carry zero internal human attribution and do not verify your container's installed PURLs.

Defensible call: Audit inbound CSAF 2.0 files via POST /api/v1/vex?fail_on=kev_conflict,missing_author before minting organization records.

Standalone Rust Trivy/Grype/CSAF suppression gate: validate expired_at, runtime PURL drift, KEV conflicts, and FNV-1a/SHA-style integrity.

Save as verify_suppressions.rs and compile with rustc --edition 2021 verify_suppressions.rs -o verify_suppressions. Zero external crates. Parses .trivyignore.yaml and .grype.yaml rules alongside a container PURL manifest (react-dom vs react-server-dom-webpack), failing non-zero on missing or lapsed expired_at dates, not_affected claims against CISA KEV (CVE-2025-55182), or forbidden runtime PURL drift.

Verification artifact · rust · compiled cleanly by build gate
use std::env;
use std::fs;
use std::process;

#[derive(Default, Debug)]
struct Rule {
    source: &'static str,
    cve: String,
    expired_at: String,
    statement: String,
    forbidden_purl: String,
}

fn parse_rules(input: &str) -> Vec<Rule> {
    let mut out = Vec::new();
    let mut cur: Option<Rule> = None;
    for raw in input.lines() {
        let line = raw.trim();
        if line.is_empty() || line.starts_with('#') {
            continue;
        }
        if let Some(rest) = line.strip_prefix("- id:") {
            if let Some(prev) = cur.take() {
                out.push(prev);
            }
            cur = Some(Rule {
                source: "trivy",
                cve: rest.trim().trim_matches('"').to_string(),
                ..Rule::default()
            });
        } else if let Some(rest) = line.strip_prefix("- vulnerability:") {
            if let Some(prev) = cur.take() {
                out.push(prev);
            }
            cur = Some(Rule {
                source: "grype",
                cve: rest.trim().trim_matches('"').to_string(),
                ..Rule::default()
            });
        } else if let Some(rest) = line.strip_prefix("expired_at:") {
            if let Some(c) = cur.as_mut() {
                c.expired_at = rest.trim().trim_matches('"').to_string();
            }
        } else if let Some(rest) = line.strip_prefix("statement:").or_else(|| line.strip_prefix("reason:")) {
            if let Some(c) = cur.as_mut() {
                let s = rest.trim().trim_matches('"').to_string();
                if let Some(idx) = s.find("forbid_purl=") {
                    let tail = &s[idx + "forbid_purl=".len()..];
                    c.forbidden_purl = tail.split_whitespace().next().unwrap_or("").to_string();
                }
                if let Some(idx) = s.find("review_by=") {
                    if c.expired_at.is_empty() {
                        let tail = &s[idx + "review_by=".len()..];
                        c.expired_at = tail.split(|ch: char| ch.is_whitespace() || ch == ']').next().unwrap_or("").to_string();
                    }
                }
                c.statement = s;
            }
        }
    }
    if let Some(prev) = cur {
        out.push(prev);
    }
    out
}

fn is_kev_listed(cve: &str) -> bool {
    matches!(cve, "CVE-2025-55182" | "CVE-2021-44228" | "CVE-2024-23113" | "CVE-2023-4966")
}

fn fnv1a64(bytes: &[u8]) -> u64 {
    let mut h: u64 = 0xcbf29ce484222325;
    for &b in bytes {
        h ^= b as u64;
        h = h.wrapping_mul(0x100000001b3);
    }
    h
}

const SAMPLE_RULES: &str = "\
# WITHHELD CVE-2025-55182 (kev_conflict_not_affected) proof=https://app.vciy.com/r/chain-kev
vulnerabilities:
  - id: CVE-2024-21626
    expired_at: 2027-03-01T00:00:00Z
    statement: \"[not_affected review_by=2027-03-01 by alex@freedom.press] forbid_purl=pkg:golang/github.com/opencontainers/runc@1.1.11 Proof: https://app.vciy.com/r/80860e8a\"\n";

const SAMPLE_IMAGE_PURLS: &[&str] = &[
    "pkg:npm/react-dom@19.2.1",
    "pkg:deb/debian/zlib1g@1:1.3.dfsg+really1.3.1-1",
];

fn main() {
    let args: Vec<String> = env::args().collect();
    let today = env::var("VCIY_TODAY_UTC").unwrap_or_else(|_| "2026-11-26".to_string());
    let raw = if args.len() > 1 {
        fs::read_to_string(&args[1]).unwrap_or_else(|e| {
            eprintln!("read error: {}", e);
            process::exit(2);
        })
    } else {
        SAMPLE_RULES.to_string()
    };

    let rules = parse_rules(&raw);
    let mut violations = 0usize;
    let mut chain_digest: u64 = 0;
    for r in &rules {
        let date_prefix = r.expired_at.get(0..10).unwrap_or("");
        let missing_expiry = date_prefix.len() != 10;
        let expired = !missing_expiry && date_prefix < today.as_str();
        let missing_proof = !r.statement.contains("https://");
        let kev_conflict = is_kev_listed(&r.cve) && r.statement.contains("[not_affected");
        let purl_drift = !r.forbidden_purl.is_empty()
            && SAMPLE_IMAGE_PURLS.iter().any(|p| *p == r.forbidden_purl);
        let ok = !missing_expiry && !expired && !missing_proof && !kev_conflict && !purl_drift;
        if !ok {
            violations += 1;
        }
        let line_fp = format!("{}|{}|{}|{}", chain_digest, r.cve, date_prefix, ok);
        chain_digest = fnv1a64(line_fp.as_bytes());
        println!(
            "src={:<5} cve={:<15} expiry={:<10} kev_conflict={:<5} purl_drift={:<5} pass={}",
            r.source,
            r.cve,
            if missing_expiry { "MISSING" } else { date_prefix },
            kev_conflict,
            purl_drift,
            ok
        );
    }
    println!("rules={} today={} violations={} receipt={:016x}", rules.len(), today, violations, chain_digest);
    if violations > 0 {
        process::exit(1);
    }
}
// Sample output:
// src=trivy cve=CVE-2024-21626  expiry=2027-03-01 kev_conflict=false purl_drift=false pass=true
// rules=1 today=2026-11-26 violations=0 receipt=...

What travels.

Bind container suppressions to review_by dates and runtime package PURLs.

Repo-wide .trivyignore CVE lines survive Dockerfile and package-lock.json changes that pull vulnerable packages into production layers.

Withhold not_affected suppressions automatically when CISA KEV lists the CVE.

On CVE-2025-55182 (Meta CNA 10.0, cvss_nvd = null, due 2025-12-12), KEV status must override stale not_affected ignore entries.

Compile .trivyignore.yaml, .grype.yaml, OpenVEX, and CSAF 2.0 from one record.

Generating all four outputs from /api/v1/suppressions prevents drift between PR checks, container registries, and downstream advisories.

Audit third-party CSAF 2.0 and OpenVEX files for named human signers before import.

Posting inbound VEX files to POST /api/v1/vex?fail_on=kev_conflict,missing_author blocks unattributed coordinator waivers at the door.

A bare CVE in Git outlives the container it cleared; a generated VEX feed expires on schedule.

Jonathan Corners · Founder, Voxell, Inc. · Referenced records: CVE-2025-55182, CVE-2024-21626