Skip to content
RCE Write-up Intermediate

SugarCRM <= 9.0.1 Multiple PHP Code Injection Vulnerabilities

The SugarCRM application allows a System Administrator to inject arbitrary settings into the config_override.php file via the Locale action in the Administration module. This can be exploited to inject and execute arbitrary PHP code, for example by setting the system log file extension to .php.

karmainsecurity.com

Published on karmainsecurity.com

https://support.sugarcrm.com/Documentation/SugarVersions/9.0/Ent/Sugar9.0.2ReleaseNotes

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 insufficient input validation or sanitisation when writing user-supplied settings to config_override.php, allowing PHP code injection.

Impact

An attacker with a System Administrator account could execute arbitrary PHP code on the server, potentially leading to full compromise.

What the attacker needed

System Administrator account

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.

SugarCRM is a customer relationship management system. A user with high privileges (System Administrator) can change settings that are written into a configuration file. Because the application does not properly check what is written, an attacker with that account can add PHP code to the file, and when the file is run by the web server, the code executes. This means the attacker can run commands on the server.

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.