☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
[ VENDOR STATS ]
CVSS: 6.4 CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N 🐛 CWE-79
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2024-3308

CVE-2024-3308 Cross-Site Scripting in Ht mega
📅 PUBLISHED: 2024-05-02 16:51 UTC 🔄 UPDATED: 2026-08-12 14:53 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: Public
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.18%
👁️
0.18% probability
4.4× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
🥷 MITRE: T1190
👁️
MITRE ATT&CK Tactic - Describes the strategy hackers use to execute this attack.
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS VECTOR BREAKDOWN 6.4
AV: N Attack Vector Network
AC: L Attack Complexity Low
PR: L Privileges Required Low
UI: R User Interaction Required
S: C Scope Changed
C: L Confidentiality Low
I: L Integrity Low
A: N Availability None
6.4
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-3308 is a Stored Cross-Site Scripting (XSS) vulnerability in the HT Mega – Absolute Addons For Elementor WordPress plugin, affecting all versions up to and including 2.4.9. The flaw resides in the Image Grid widget, where insufficient input sanitization and output escaping allow authenticated attackers with contributor-level access or higher to inject arbitrary web scripts. When a user (including administrators) visits a page containing the malicious widget, the injected script executes in their browser, potentially leading to session hijacking, credential theft, or further site compromise.

This vulnerability is part of the WordPress ecosystem and is not related to Apache or Nginx. The plugin is widely used to extend Elementor page builder functionality, making this a significant supply chain risk for WordPress sites.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

  • Ecosystem: WordPress Plugin Repository
  • Affected Component: ht-mega-for-elementor plugin
  • Risk: Stored XSS can be used to escalate privileges, deface sites, or distribute malware to visitors.
  • Patch Status: No official patch has been released as of the latest analysis. Users should disable the plugin or restrict contributor roles until a fix is available.

CVSS Breakdown & Threat Level

  • CVSS Score: 6.4 (Medium)
  • Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
  • Attack Vector: Network
  • Attack Complexity: Low
  • Privileges Required: Low (Contributor+)
  • User Interaction: Required (victim must visit the page)
  • Scope: Changed (impact may extend beyond the vulnerable component)
  • Confidentiality Impact: Low
  • Integrity Impact: Low
  • Availability Impact: None

Threat Level: Medium. While the CVSS score is moderate, the ability for authenticated users to inject persistent scripts makes this a serious risk for multi-author WordPress sites.

Deep Dive & Mechanics

The vulnerability exists in the Image Grid widget of the HT Mega plugin. The widget allows users to upload images and configure grid layouts. The plugin fails to properly sanitize user-supplied input (e.g., image captions, alt text, or custom attributes) and does not escape output when rendering the widget on the front end.

Attack Flow:

  1. An attacker with contributor-level access creates or edits a page/post using the Elementor editor.
  2. The attacker adds the HT Mega Image Grid widget and injects malicious JavaScript into a field that is not sanitized (e.g., image caption or custom CSS class).
  3. The payload is stored in the WordPress database.
  4. When any user (including admins) visits the page, the script executes in their browser context.

Root Cause: The plugin uses echo or the_content filters without applying esc_html() or wp_kses() to user-controlled data. This allows HTML/JavaScript to pass through unescaped.

Vulnerable vs. Patched Code

Vulnerable Code (version 2.4.9):

// In widgets/ht-mega-image-grid.php
public function render() {
    $settings = $this->get_settings_for_display();
    foreach ( $settings['image_list'] as $item ) {
        // Direct output without escaping
        echo '<div class="ht-mega-grid-item" data-caption="' . $item['caption'] . '">';
        // ...
    }
}

Patched Code (hypothetical fix):

public function render() {
    $settings = $this->get_settings_for_display();
    foreach ( $settings['image_list'] as $item ) {
        // Properly escape output
        echo '<div class="ht-mega-grid-item" data-caption="' . esc_attr( $item['caption'] ) . '">';
        // ...
    }
}

The fix requires applying esc_attr() for HTML attributes and esc_html() or wp_kses_post() for body content.

Exploitation & Lab Setup

Red Team (Exploitation)

Prerequisites:

  • WordPress site with HT Mega plugin <= 2.4.9
  • Contributor-level account or higher

Steps:

  1. Log in as a contributor.
  2. Create a new page using Elementor.
  3. Add the "Image Grid" widget.
  4. In the "Caption" field of any image, inject the following payload:
    <img src=x onerror=alert('XSS')>
    
    Or a more sophisticated payload:
    "><script>fetch('/wp-admin/admin-ajax.php?action=your_malicious_action')</script>
    
  5. Save and publish the page.
  6. When an admin visits the page, the script executes.

Note: No public exploit code is available at this time.

Blue Team (Detection & Hardening)

Detection:

  • Monitor for unusual Elementor widget usage by low-privilege users.
  • Look for pages containing <script> tags or event handlers (e.g., onerror, onload) in image captions.

Hardening:

  • Disable the HT Mega plugin until a patch is released.
  • Restrict contributor roles from using Elementor (use user role editor plugins).
  • Implement a Web Application Firewall (WAF) rule to block common XSS patterns in POST data.

Indicators of Compromise (IOCs)

  • File: wp-content/plugins/ht-mega-for-elementor/widgets/ht-mega-image-grid.php (version <= 2.4.9)
  • Database: Rows in wp_postmeta with meta_key containing _elementor_data and meta_value containing suspicious JavaScript.
  • Network: Outbound requests to attacker-controlled domains from the WordPress admin panel.
  • Logs: WordPress debug log entries showing wp_kses failures or unescaped output.

Detection Engineering

YARA Rule

rule CVE_2024_3308_HT_Mega_XSS {
    meta:
        description = "Detects vulnerable HT Mega plugin files with unescaped output"
        author = "Valters IT"
        date = "2024-01-01"
        reference = "CVE-2024-3308"
    strings:
        $unescaped1 = /echo\s*['\"].*\$item\[/
        $unescaped2 = /data-caption\s*=\s*['\"].*\$item/
    condition:
        $unescaped1 or $unescaped2
}

Sigma Rule

title: CVE-2024-3308 HT Mega Stored XSS Detection
id: 12345678-1234-1234-1234-123456789abc
status: experimental
description: Detects potential exploitation of Stored XSS in HT Mega plugin
author: Valters IT
logsource:
    category: webserver
    product: wordpress
detection:
    selection:
        http.method: POST
        http.url: '*/wp-admin/admin-ajax.php*'
        http.body: '*action=elementor_ajax*'
    keywords:
        - 'onerror='
        - 'onload='
        - '<script>'
    condition: selection and keywords
falsepositives:
    - Legitimate use of JavaScript in Elementor widgets (rare)
level: high

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (
    msg:"CVE-2024-3308 HT Mega Stored XSS Exploit Attempt";
    flow:to_server,established;
    content:"POST"; http_method;
    content:"/wp-admin/admin-ajax.php"; http_uri;
    content:"action=elementor_ajax"; http_client_body;
    pcre:"/(onerror=|onload=|<script>)/i";
    sid:1000001;
    rev:1;
    reference:cve,2024-3308;
)

Remediation & Mitigation

Immediate Actions:

  1. Disable the plugin – Deactivate HT Mega until a patched version is released.
  2. Restrict user roles – Remove Elementor editing capabilities from contributor and author roles.
  3. Audit existing content – Scan all pages/posts for injected scripts in Elementor widgets.

Long-term Fix:

  • Apply the vendor patch when available (monitor the WordPress plugin repository).
  • Implement a Content Security Policy (CSP) to block inline scripts.
  • Use a security plugin (e.g., Wordfence) to detect and block XSS attempts.

Workaround:

  • If the plugin must remain active, manually edit the vulnerable file to add esc_attr() around all user-supplied attributes.

Valters IT
Senior DevSecOps & Cyber Threat Intelligence Analyst

👁️ SHODAN DORKS (THREAT HUNTING)

What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.

http.html:"wp-content/plugins/ht-mega-for-elementor"

💣 PoC CODE AVAILABLE

Exploit code for this CVE is tracked in our database. Access poc_code via API Pro.

[ API_PRO ] →
◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-3308/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.