CVE-2024-38706
📋 TL;DR
This path traversal vulnerability in the HT Mega WordPress plugin allows attackers to access files outside the intended directory by manipulating file paths. It affects all versions up to 2.5.7 of the plugin, potentially exposing sensitive server files to unauthorized users.
💻 Affected Systems
- HasThemes HT Mega WordPress Plugin
📦 What is this software?
Ht Mega by Hasthemes
⚠️ Risk & Real-World Impact
Worst Case
Attackers could read sensitive system files like /etc/passwd, configuration files, or source code, potentially leading to further system compromise.
Likely Case
Unauthorized access to WordPress configuration files, plugin files, or other web-accessible files containing sensitive information.
If Mitigated
Limited to reading files within the web server's accessible directory structure, with no write or execution capabilities.
🎯 Exploit Status
Exploitation involves simple path manipulation in JSON requests. Public proof-of-concept available through Patchstack.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: 2.5.8 or later
Vendor Advisory: https://patchstack.com/database/vulnerability/ht-mega-for-elementor/wordpress-ht-mega-plugin-2-5-7-json-path-traversal-vulnerability
Restart Required: No
Instructions:
1. Log into WordPress admin panel. 2. Go to Plugins → Installed Plugins. 3. Find 'HT Mega - Absolute Addons For Elementor'. 4. Click 'Update Now' if available. 5. Alternatively, download version 2.5.8+ from WordPress repository and manually update.
🔧 Temporary Workarounds
Disable HT Mega Plugin
allTemporarily disable the vulnerable plugin until patched
wp plugin deactivate ht-mega
Web Application Firewall Rule
allBlock requests containing path traversal patterns to HT Mega endpoints
🧯 If You Can't Patch
- Implement strict file access controls and directory permissions
- Monitor web server logs for path traversal attempts to HT Mega endpoints
🔍 How to Verify
Check if Vulnerable:
Check WordPress admin → Plugins → HT Mega version. If version is 2.5.7 or earlier, system is vulnerable.
Check Version:
wp plugin get ht-mega --field=version
Verify Fix Applied:
Verify HT Mega plugin version is 2.5.8 or later in WordPress admin panel.
📡 Detection & Monitoring
Log Indicators:
- HTTP requests to /wp-json/htmega/v1/ with ../ patterns in parameters
- File access attempts outside plugin directory
Network Indicators:
- Requests to HT Mega JSON endpoints with directory traversal sequences
SIEM Query:
web_access_logs WHERE uri CONTAINS '/wp-json/htmega/v1/' AND (uri CONTAINS '../' OR parameters CONTAINS '%2e%2e%2f')