Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

GHSA-5vwr-qchf-q4pf: @cyclonedx/cdxgen: Maven project scanning may allow shell command injection through repository-controlled module paths

0
Medium
Published: 06/26/2026 (06/26/2026, 19:47:24 UTC)
Source: GCVE Database
Product: @cyclonedx/cdxgen

Description

A command injection vulnerability exists in the Maven scanning flow of cdxgen versions prior to 12.4.3. The vulnerability arises because some Maven commands were executed with shell: true, allowing repository-controlled directory names containing shell metacharacters to be interpreted by the shell. This could enable an attacker controlling a scanned Maven project repository to execute arbitrary commands in the cdxgen process context. The issue affects both CLI and server modes and is patched in version 12.4.3.

CVSS v4.0

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vuln. Confidentiality
Low
Vuln. Integrity
Low
Vuln. Availability
None
Subsq. Confidentiality
Low
Subsq. Integrity
Low
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

Affected software

npmghsa
@cyclonedx/cdxgen
Affected versions
<12.4.3

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 06/26/2026, 22:09:50 UTC

Technical Analysis

cdxgen before version 12.4.3 contains a command injection vulnerability in its Maven scanning functionality. When scanning an attacker-controlled Maven project, repository-controlled paths could be injected into Maven command invocations that used shell: true on POSIX platforms. This allowed shell metacharacters in directory names to be interpreted by the shell, potentially enabling command execution within the cdxgen process. The vulnerability affects both CLI and server modes, specifically the POST /sbom endpoint in server mode. The patch in 12.4.3 mitigates this by removing unconditional shell execution, blocking shell: true invocations with unsafe arguments, and adding other hardening measures. Residual risks remain for nested paths interpreted by external build tools after cdxgen launches them, so sandboxing untrusted scans is recommended.

Potential Impact

An attacker who controls a scanned Maven project repository can exploit this vulnerability to execute arbitrary shell commands in the context of the cdxgen process. This could lead to unauthorized code execution during scanning operations. The vulnerability affects both CLI and server modes of cdxgen. However, exploitation requires control over the scanned repository paths and the ability to trigger scans. There are no known exploits in the wild as of the published date.

Mitigation Recommendations

A fix is available in cdxgen version 12.4.3 and later, which hardens command invocation by removing unconditional shell execution and blocking unsafe shell arguments. The recommended remediation is to upgrade to version 12.4.3 or later. If immediate upgrade is not possible, apply mitigations such as not running cdxgen server mode on untrusted networks, restricting access to the POST /sbom endpoint, avoiding scanning untrusted Maven repositories, running cdxgen in sandboxed or containerized environments, removing sensitive environment variables, using least-privilege filesystem mounts, and restricting outbound network access. Use cdxgen secure/dry-run modes and configure host and command allowlists to reduce exposure. These mitigations reduce but do not fully eliminate risk in affected versions.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
GHSA-5vwr-qchf-q4pf
Osv Schema Version
1.4.0
Aliases
[]
Ecosystems
["npm"]
Database Specific Severity
MODERATE
Cvss Version
4.0

Threat ID: 6a3ef76e27e9c79719fee9dc

Added to database: 06/26/2026, 22:04:30 UTC

Last enriched: 06/26/2026, 22:09:50 UTC

Last updated: 06/26/2026, 22:09:50 UTC

Views: 2

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses