All vulnerabilities

Servers and applications

CVE-2026-34049

Incomplete fix for CVE-2025-66209: Command Injection via unsanitized MongoDB collection names in database backup

Severity
Low 3.3
Published
2 Jul 2026
Last changed
2 Jul 2026
Added to UpHeron
22 Oct 2026
Fixed in
4.0.0-beta.471
Exploit chance
0.2% in the next 30 daysHigher than 15% of CVEs. EPSS by FIRST, 19 Nov 2026
Weakness
OS command injection (CWE-78)
Attack
Over the network · Only under certain conditions · Needs an administrator account · No user action needed
Attacker can
Read some data · Change some data
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:L/I:L/A:N
Also known as
GHSA-4mpw-wcj4-v9pp
Sources
Project advisories (GitHub)

Description

The fix for CVE-2025-66209 in Coolify v4.0.0-beta.451 is incomplete. While database names in the databases_to_backup field are now validated with validateShellSafePath() and escaped with escapeshellarg(), MongoDB collection names specified in the same field (format: dbname:collection1,collection2) are never validated or escaped. An authenticated user with database backup permissions can inject arbitrary shell commands via collection names, achieving full remote code execution on the managed server. Tested on v4.0.0-beta.469 (commit 06f60c9a98bead0c932c6adf7fd43a45d9149048).

The databases_to_backup field for MongoDB databases supports a special format: dbname:collection1,collection2|dbname2:collection3 where the part after : specifies collections to exclude.

In app/Jobs/DatabaseBackupJob.php, the CVE-2025-66209 fix correctly validates and escapes the database name, but the collection names are directly interpolated into the shell command without any sanitization:

From coollabsio/coolify's security advisory. Shortened; the full text is there.

Affected software

SoftwareAffected versions
CoolifyServers and applications · github:coollabsio/coolify
  • From 4.0.0-beta.451 before 4.0.0-beta.471

About Coolify

An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.

From its GitHub repository.
Docker Hub pulls
4,970,195Docker Hub, 15 Nov 2026
GitHub stars
66,095GitHub, 15 Nov 2026
Forks
5,989GitHub, 15 Nov 2026
Latest release
v4.7.5GitHub, 15 Nov 2026
Released
10 Nov 2026GitHub
License
Apache-2.0GitHub
First published on GitHub
25 Jan 2021GitHub

References