Dokploy Command Injection Vulnerability in Docker File Upload Functionality Allowing Remote Code Execution

Vulnerability

A command injection vulnerability allowing remote code execution has been identified in Dokploy versions through 0.29.1. The issue arises in the Docker file upload feature, where the destinationPath parameter is not properly sanitized. This flaw allows authenticated users to interpolate shell metacharacters into a command string, escaping the intended docker cp command and executing arbitrary operating system commands on the Dokploy host.

Impact

Exploitation of this vulnerability allows for arbitrary command execution on the Dokploy host, with the executed commands running in the context of the user running the Dokploy application.

Reproduction

To reproduce this vulnerability, log in to Dokploy as an authenticated user and upload a file to any container. Intercept the upload request and modify the destinationPath parameter to include shell metacharacters, such as a semicolon followed by a command (e.g., 'id' or 'uname -a'). Once the request is sent, the server will execute the injected commands, demonstrating the command execution vulnerability.

Remediation

To address this vulnerability, it is recommended to validate the destinationPath parameter against a strict regular expression that disallows shell metacharacters. Additionally, use execFile or spawn with an array of arguments instead of string interpolation with exec, to prevent command injection.

Added: May 29, 2026, 4:20 PM
Updated: May 29, 2026, 4:20 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
10.0
exploitability
6.6
remediation
0.0
relevance
9.6
threat
6.4
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.