CVE-2024-47051

9.1 CRITICAL

📋 TL;DR

This CVE addresses two critical vulnerabilities in Mautic versions before 5.2.3: a Remote Code Execution (RCE) via asset upload that allows authenticated users to upload executable PHP files, and a Path Traversal vulnerability that enables arbitrary file deletion. Organizations running vulnerable Mautic instances with authenticated user accounts are affected.

💻 Affected Systems

Products:
  • Mautic
Versions: All versions before 5.2.3
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Requires authenticated user access; both vulnerabilities can be exploited by users with appropriate permissions.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete system compromise allowing attackers to execute arbitrary code, delete critical system files, and potentially gain persistent access to the entire server infrastructure.

🟠

Likely Case

Data loss, service disruption, and potential lateral movement within the network as attackers exploit authenticated access to manipulate files and execute malicious code.

🟢

If Mitigated

Limited impact if proper file upload restrictions and authentication controls are in place, though authenticated users could still cause damage.

🌐 Internet-Facing: HIGH
🏢 Internal Only: HIGH

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires authenticated access but is straightforward once authentication is obtained.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 5.2.3

Vendor Advisory: https://github.com/mautic/mautic/security/advisories/GHSA-73gx-x7r9-77x2

Restart Required: No

Instructions:

1. Backup your Mautic instance and database. 2. Update to Mautic version 5.2.3 or later via the built-in updater or manual installation. 3. Verify the update completed successfully.

🔧 Temporary Workarounds

Restrict File Upload Extensions

all

Implement strict file extension validation at the web server level to block PHP and other executable file uploads.

# For Apache: Add to .htaccess
<FilesMatch "\.(php|phtml|php3|php4|php5|php7|phps|phar)$">
    Order Allow,Deny
    Deny from all
</FilesMatch>
# For Nginx: Add to server block
location ~ \.(php|phtml|php3|php4|php5|php7|phps|phar)$ {
    deny all;
}

Restrict User Permissions

all

Limit authenticated user permissions to only essential functions and implement principle of least privilege.

🧯 If You Can't Patch

  • Implement strict network segmentation to isolate Mautic instances from critical systems.
  • Deploy web application firewall (WAF) rules to block suspicious file upload patterns and path traversal attempts.

🔍 How to Verify

Check if Vulnerable:

Check Mautic version in the admin dashboard or via the database: SELECT * FROM mautic_core_config WHERE bundle = 'core' AND name = 'mautic_version'

Check Version:

php bin/console mautic:version

Verify Fix Applied:

Confirm version is 5.2.3 or higher in the admin dashboard or via the version check command.

📡 Detection & Monitoring

Log Indicators:

  • Unusual file uploads with PHP extensions
  • Failed file deletion attempts with unusual paths
  • Multiple authentication attempts followed by file operations

Network Indicators:

  • POST requests to asset upload endpoints with executable file types
  • HTTP requests containing path traversal sequences (../)

SIEM Query:

source="mautic_logs" AND (file_extension="php" OR path="*../*")

🔗 References

📤 Share & Export