HIGH 7.5

CVE-2026-55092: Trivy Path Traversal Vulnerability in OCI Artifact Download

Trivy, a popular container security scanner, has a path traversal vulnerability in versions before 0.71.1. When Trivy downloads container images (OCI artifacts), it reads a label called 'org.opencontainers.image.title' from the image metadata and uses it as a filename without checking whether that filename could escape the intended directory. An attacker who controls a container image can craft this label to include path traversal sequences (like '../'), tricking Trivy into writing downloaded content to arbitrary locations on the host system. This could allow an attacker to overwrite critical files or place malicious content where it will be executed.

Source data · NVD / CISA · public domain

CVSS
3.1 · 7.5 HIGH · CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Weaknesses (CWE)
CWE-22
Affected products
1 configuration(s)
Published / Modified
2026-06-25 / 2026-06-27

NVD description (verbatim)

Trivy is a security scanner. Prior to 0.71.1, when Trivy downloads an OCI artifact, it uses the org.opencontainers.image.title annotation from the artifact manifest as the destination filename without validation. An attacker who can make Trivy fetch an attacker-controlled artifact can supply a crafted annotation that resolves to a path outside the intended destination, causing Trivy to write the layer content to an arbitrary location on the host filesystem. This vulnerability is fixed in 0.71.1.

1 reference(s) · View on NVD →

SEC.co analysis · AI-assisted, reviewed against source

Technical summary

CVE-2026-55092 is a path traversal vulnerability (CWE-22) in Trivy versions prior to 0.71.1. The vulnerability exists in the OCI artifact download mechanism. Trivy extracts the org.opencontainers.image.title annotation from an OCI artifact manifest and uses it directly as a destination filename without sanitization or validation. An attacker controlling a malicious OCI artifact can embed path traversal sequences in the annotation value, causing Trivy to write layer content to paths outside the intended extraction directory. The CVSS 3.1 score of 7.5 (HIGH) reflects the network-accessible nature of the vulnerability, the lack of authentication required, and the ability to modify files on the filesystem, though without direct confidentiality impact.

Business impact

Organizations using Trivy in automated security scanning pipelines face a material risk. If Trivy is integrated into CI/CD workflows, build systems, or container registries, an attacker could potentially overwrite system configuration files, application binaries, or other critical assets by serving a malicious container image. This could lead to supply chain compromise, loss of scanning integrity, or lateral movement within the environment. The impact is amplified in containerized environments where Trivy may run with elevated privileges or in shared infrastructure.

Affected systems

Trivy versions prior to 0.71.1 are affected. Any deployment of Trivy that downloads OCI artifacts is vulnerable, including container registry scanning, CI/CD pipeline security checks, and standalone vulnerability assessments. The vulnerability is present across all platforms where Trivy runs (Linux, macOS, Windows).

Exploitability

Exploitability is moderate to high. The vulnerability requires an attacker to control or influence an OCI artifact that Trivy will download—this could occur if Trivy is configured to scan a registry namespace controlled by the attacker, or if the attacker can compromise a legitimate registry. Once the artifact is fetched, exploitation is automatic; no user interaction or special configuration is needed. The attack surface is widest in environments where Trivy scans untrusted or externally-sourced container images. The vulnerability is not currently listed on the CISA Known Exploited Vulnerabilities catalog.

Remediation

Upgrade Trivy to version 0.71.1 or later, which implements proper validation and sanitization of the org.opencontainers.image.title annotation, preventing path traversal attacks. No workarounds are available for older versions. Organizations should prioritize this patch, especially if Trivy operates in CI/CD environments or scans container images from multiple sources.

Patch guidance

Update Trivy to version 0.71.1 or later. For containerized deployments, rebuild or redeploy with the patched image. For package manager installations (apt, brew, yum, etc.), use the standard update mechanism. Verify the upgrade by running 'trivy version' and confirming the reported version is 0.71.1 or higher. No configuration changes are required; the patch is transparent to end users.

Detection guidance

Monitor Trivy logs and filesystem access patterns for evidence of unexpected file writes outside standard Trivy directories. Watch for Trivy processes attempting to write files to system paths (/etc, /usr/bin, /var, etc.) or application directories. Network monitoring can identify attempts to fetch OCI artifacts from unexpected or untrusted registries. If Trivy is instrumented with audit logging, examine for any malformed org.opencontainers.image.title annotations that contain path traversal sequences. Correlate timing of Trivy execution with filesystem modifications.

Why prioritize this

This vulnerability merits immediate attention despite not being actively exploited in the wild (no CISA KEV listing) because: (1) it enables arbitrary file write with network accessibility and no authentication, (2) Trivy is widely deployed in security-critical supply chain workflows, and (3) successful exploitation could compromise the integrity of the systems or software Trivy is meant to protect. Organizations should treat this as a high-priority patch.

Risk score, explained

The CVSS 3.1 score of 7.5 reflects a HIGH-severity vulnerability. The network vector (AV:N) indicates remote exploitability, low complexity (AC:L) means no special conditions are needed, no privilege requirement (PR:N), no user interaction (UI:N), and unchanged scope (S:U). The integrity impact (I:H) is high because arbitrary files can be written. Confidentiality and availability impacts are not directly affected, explaining why the score does not reach critical. The practical risk is elevated by Trivy's role in securing supply chains.

Frequently asked questions

Do I need to upgrade immediately if we use Trivy in our CI/CD pipeline?

Yes. If Trivy scans any container images sourced from untrusted or externally-controlled registries, or if multiple teams can influence artifact sources, upgrade to 0.71.1 or later without delay. Even internal registries can be compromised, so this should be treated as a critical patch.

What happens if a malicious annotation is encountered in a patched version?

Version 0.71.1 validates and sanitizes the org.opencontainers.image.title annotation before using it as a filename. Path traversal sequences are rejected or escaped, preventing writes outside the intended directory. The artifact download either fails safely or the annotation is discarded in favor of a safe default.

Can this vulnerability affect Trivy when it's used only to scan local files or pre-downloaded images?

No. The vulnerability is specific to the OCI artifact download mechanism. If Trivy is used only to analyze container images already on disk or to scan local filesystems without downloading artifacts, this CVE does not apply. However, most Trivy deployments in CI/CD environments do download artifacts, so it is prudent to patch anyway.

Is there a way to restrict which registries Trivy can download from?

Trivy itself does not have built-in registry allowlisting. As a temporary mitigation on older versions, you can use network-level controls (firewall rules, proxy allowlists) to restrict outbound connections to trusted registries only. However, this is not a substitute for upgrading; it reduces the attack surface but does not fix the underlying vulnerability.

This analysis is for informational purposes and represents SEC.co's assessment of publicly disclosed vulnerability data as of the publication date. The information provided should not be considered a substitute for a comprehensive security audit or vendor advisory review. Actual risk depends on your specific environment, Trivy version, registry configuration, and threat model. Always consult the official Aqua Security Trivy advisory and release notes before implementing patches. Patch versions, timelines, and workarounds may change; verify against authoritative vendor sources before taking action. Source: NVD (public-domain), retrieved 2026-08-03. Analysis generated by SEC.co (claude-haiku-4-5).