Skip to content
RCE Write-up Intermediate

Control Web Panel <= 0.9.8.1208 (admin/index.php) OS Command Injection Vulnerability

The admin endpoint passes the 'key' GET parameter into an OS command without sanitisation when the 'api' parameter is set. An unauthenticated attacker could inject and run arbitrary commands as root, provided Softaculous or SitePad is installed.

karmainsecurity.com

Published on karmainsecurity.com

User input passed via the “key” GET parameter to /admin/index.php (when the “api” parameter is set) is not properly sanitized before being used to execute OS commands. This can be exploited by unauthenticated attackers to inject and execute arbitrary OS commands with the privileges of the root user on the web server.

The author, on karmainsecurity.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the application concatenates the 'key' parameter into a shell command string without escaping or validating it.

Impact

An unauthenticated attacker could execute arbitrary OS commands with root privileges, but only if Softaculous and/or SitePad is installed through the Scripts Manager.

What the attacker needed

Softaculous and/or SitePad installed; Network access to /admin/index.php

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

This software builds a system command using text supplied by the visitor. Because the text is not cleaned, a visitor can add extra command parts and the server runs them. The commands run as the most powerful user on the machine, so the whole server can be taken over.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.