Coolify
CVE-2025-66211
CRITICAL
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAuthenticate with app/service management role
-
DeliverySet malicious PostgreSQL init-script filename
-
ExploitInjection in unescaped shell command
-
ExecutionExecute arbitrary command as root
-
ImpactFull managed-server compromise
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK
2 techniques across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires an authenticated Coolify account holding application or service management permissions on an instance that manages at least one PostgreSQL database; the attacker supplies a crafted PostgreSQL initialization-script filename (via save_init_script in the Postgresql General component) - or, per the fix, a crafted database name in backup configuration - containing shell metacharacters that are passed unvalidated into rm/pg_dump/docker shell commands. Limiting factors: it is NOT pre-authentication (PR:L - a valid account with config/management rights is mandatory), so single-admin self-hosted instances are only self-exploitable, whereas multi-user or multi-tenant deployments with lower-trust operators are genuinely exposed. Affects all 4.0.0 beta builds prior to beta.451. |
| Impact | This is a genuinely high-severity issue but not a mass-exploitation emergency. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:L/UI:N) and the 9.4 score reflect network-reachable, low-complexity exploitation that nonetheless requires authentication (PR:L) - specifically a user who already holds application/service management permissions. The impact metrics are maximal (VC/VI/VA:H plus subsequent-system SC/SI/SA:H), consistent with the description's claim of arbitrary command execution as root on managed servers, which crosses from the Coolify application's authority into full control of downstream hosts. Signals are partially conflicting on urgency: a public POC exists (a GitHub exploit repo is referenced), which raises practical risk, yet EPSS is only 0.41% (61st percentile) and the CVE is NOT listed in CISA KEV, indicating no confirmed active exploitation and low modeled probability of widespread attacks. The PR:L requirement is the key moderating factor - this is a privilege-escalation-to-RCE for an already-authenticated, semi-trusted operator rather than a pre-auth internet worm. Net: a real priority for any multi-tenant or shared Coolify deployment where lower-privileged users exist, but lower practical risk for single-admin self-hosted instances. Note the referenced exploit repo is titled for CVE-2025-66209/66213 rather than this exact CVE number - verify POC applicability to the PostgreSQL init-script vector specifically. |
| Exploit ScenarioDerived | An authenticated Coolify user who holds application or service management permissions configures a managed PostgreSQL database and supplies a malicious init-script filename (or database backup name) containing shell metacharacters. Because the filename is interpolated into a shell command without escaping, the injected payload executes as root on the managed server when the init/backup job runs, yielding full remote code execution. A public proof-of-concept referencing this family of Coolify command-injection flaws is available, lowering the barrier to exploitation. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv2 – Oct 19, 2026
Authenticated command injection in Coolify's PostgreSQL initialization-script filename handling allows users with application or service management permissions to execute arbitrary commands as root on managed servers. All Coolify 4.0.0 beta builds prior to beta.451 are affected, publicly available exploit code exists, and the upstream fix also covers database names used in backup configuration. EPSS is low at 0.41% (61st percentile), but the impact is severe for multi-user or multi-tenant deployments where lower-trust operators hold management rights.
Earlier versions of this analysis (1)
An authenticated command injection vulnerability in Coolify's PostgreSQL initialization script handling allows attackers with application/service management permissions to execute arbitrary commands as root on managed servers. The vulnerability affects all Coolify versions prior to 4.0.0-beta.451 and enables full remote code execution through unsanitized PostgreSQL init script filenames passed to shell commands. A public proof-of-concept exploit is available, and while not currently in CISA KEV, the vulnerability has a moderate EPSS score of 0.41% indicating some exploitation probability.
RemediationAI
Upgrade to Coolify 4.0.0-beta.451 or later using the release at https://github.com/coollabsio/coolify/releases/tag/v4.0.0-beta.451 and review the advisory at https://github.com/coollabsio/coolify/security/advisories/GHSA-24mp-fc9q-c884. If immediate upgrade is not possible, restrict network access to the Coolify management interface and ensure only trusted administrators hold application or service management permissions, because exploitation requires an authenticated account with those rights; removing such permissions from lower-trust operators reduces exposure but does not fix the underlying injection. Review existing PostgreSQL init-script filenames and backup database names for shell metacharacters, remove suspicious entries, and monitor Coolify logs for unexpected shell command execution.
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Coolify is an open-source, self-hostable platform-as-a-service that orchestrates servers, applications, and databases, frequently through Docker and shell command execution. The PostgreSQL initialization-script feature stores user-supplied filenames under docker-entrypoint-initdb.d and constructs shell commands such as rm -f $old_file_path without validating shell metacharacters; the same unsafe pattern appears in backup jobs that interpolate database names into pg_dump, mysqldump, mariadb-dump, and mongodump commands. This is CWE-78 (OS Command Injection): user-controlled strings cross into a shell context, so metacharacters like semicolons, pipes, command substitution, or backticks break out of the intended command and execute as the Coolify process user, which the advisory describes as root on managed servers. The fix in PR #7375 adds validateShellSafePath() and escapeshellarg() around filenames and database names. CPE data confirms affected 4.0.0 beta builds, including beta.100 through beta.108 and earlier versions.
Know when Coolify gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
Network-reachable UI with an authenticated low-privilege operator role (PR:L), no user interaction; command runs as root on managed servers beyond Coolify's authority, so S:C with full C/I/A impact.
Primary rating from Vendor (github).
CVSS VectorVendor: github
Lifecycle Timeline
5DescriptionCVE.org
Coolify is an open-source and self-hostable tool for managing servers, applications, and databases. Prior to version 4.0.0-beta.451, an authenticated command injection vulnerability in PostgreSQL Init Script Filename handling allows users with application/service management permissions to execute arbitrary commands as root on managed servers. PostgreSQL initialization script filenames are passed to shell commands without proper validation, enabling full remote code execution. Version 4.0.0-beta.451 fixes the issue.
Executive ViewAI
Coolify, a self-hosted deployment platform, exposes every 4.0.0 beta build before beta.451 to command injection through PostgreSQL initialization-script filenames, letting anyone who already holds application or service management rights run arbitrary commands as root on the servers Coolify manages. The practical consequence is that a single mid-trust operator account becomes a root foothold over shared infrastructure, which directly undermines the isolation assumptions behind multi-tenant or multi-team hosting. There is no confirmed active exploitation, but publicly available exploit code exists and no vendor-released patch has been identified at time of analysis, so exposure is governed by how tightly management rights are currently delegated.
No vendor-released patch identified at time of analysis; the upstream fix is incorporated from Coolify 4.0.0 beta.451 onward, so upgrading to that build or later is the primary remediation. Until then: restrict application and service management permissions to a small set of trusted administrators, remove these rights from lower-trust operators and tenant-facing accounts, isolate Coolify control planes and managed servers on segmented networks with no cross-tenant reachability, monitor deployment and backup configuration activity for anomalous PostgreSQL initialization-script filenames or shell metacharacters, and audit existing database names and backup entries for injected content.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
OS command injection occurs when an application passes unsanitized user input directly into system shell commands.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
Affected Products (CPE)CVE.org
Cross-team authorization bypass in Coolify (open-source self-hosted PaaS) before 4.0.0-beta.474 allows an authenticated,
Coolify versions prior to v4.0.0-beta.420.7 are vulnerable to a remote code execution vulnerability in the project deplo
Coolify versions prior to v4.0.0-beta.420.6 are vulnerable to a remote code execution vulnerability in the application d
Command injection in Coolify up to and including v4.0.0-beta.434 lets any authenticated low-privileged 'member' execute
Remote code execution on the host OS is possible through Coolify's application deployment workflow prior to version 4.0.
Coolify versions prior to 4.0.0-beta.451 pass user-supplied database names unsanitized into shell commands executed via
Authenticated Coolify users who hold application or service management permissions can execute arbitrary commands as roo
Authenticated command injection in Coolify before 4.0.0-beta.451 lets users with application or service management permi
Stored cross-site scripting in Coolify versions up to and including v4.0.0-beta.420.6 lets an authenticated low-privileg
Authenticated OS command injection in Coolify before 4.0.0-beta.471 lets any user holding destination management permiss
Authenticated remote code execution in Coolify (self-hosted PaaS) before 4.0.0-beta.470 lets a low-privileged authentica
Command injection in Coolify's Git Repository field during project creation allows an authenticated member account to ru
NVD
CVE.org
EPSS
GitHub
Exploit-DB