Trustwave and Cybereason Merge to Form Global MDR Powerhouse for Unparalleled Cybersecurity Value. Learn More
Get access to immediate incident response assistance.
Get access to immediate incident response assistance.
Trustwave and Cybereason Merge to Form Global MDR Powerhouse for Unparalleled Cybersecurity Value. Learn More
Our web honeypots picked up some increased exploit attempts for an old Joomla Content Editor (JCE) Extension vulnerability.
Although this vulnerability is a few years old, botnet owners are heavily scanning for sites that are vulnerable and attempting to exploit them.
Here are the exploit details from the vulnerability write-up on Exploit-DB:
The first step in this attack is to attempt to upload a webshell/backdoor file to the JCE ImageManager. Here is how the attack looked in the default Apache access_log file:
This entry shows a POST request to the ImageManager Joomla Plugin using the "com_jce" option. We can also see a tell-tale sign of a malicious program in the User-Agent string value "BOT for JCE". Unfortunately, the default Apache access_log does not actually log the critical POST payload for this request so we can not see what was sent. Fortunately, we also have our ModSecurity WAF installed so we can go to the detailed audit log file to see the complete transaction. Here is the same transaction as logged by ModSecurity:
We notice a few things here:
ModSecurity has the ability to capture and store file attachments. When we inspect the "food.gif" file, we find the following:
This is an obfuscated PHP file. After decoding, we find this section of code:
This is a typical webshell/backdoor that allows the attacker to submit OS commands and upload files:
After uploading the webshell file, the attacker next needs to rename the file and change the file extension from ".gif" to ".php" so that it will be executed as code by the application. There are known exploit tools to achieve this task. Here is an example screenshot of a PHP exploit page:
The source code of the page shows the attack details:
The highlighted section show the JSON request body content that uses the "folderRename" action to change the uploaded file extension. This is how the actual attack attempt looked in the ModSecurity audit log file:
Note under Section H that our commercial rule captured this attack attempt.
The last step in the attack sequence was for the attacker to try and access the webshell file:
Since the exploit attempt did not work, the honeypot returned a 404.
Attackers are constantly scanning the internet for web sites that have out-dated software. It is critical that web site owners stay vigilant in updating their software and applying patches. In addition, using a Web Application Firewall (WAF) such as ModSecurity can also aid operational security personnel with incident response by providing essential transactional data.
Trustwave is a globally recognized cybersecurity leader that reduces cyber risk and fortifies organizations against disruptive and damaging cyber threats. Our comprehensive offensive and defensive cybersecurity portfolio detects what others cannot, responds with greater speed and effectiveness, optimizes client investment, and improves security resilience. Learn more about us.
Copyright © 2024 Trustwave Holdings, Inc. All rights reserved.