Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2024-12599 Overview
CVE-2024-12599 is a Stored Cross-Site Scripting (XSS) vulnerability in the HT Mega – Absolute Addons For Elementor plugin for WordPress. The flaw affects all versions up to and including 2.8.1 and resides in the plugin's Countdown widget. Insufficient input sanitization and output escaping on user-supplied attributes allow authenticated attackers with contributor-level access or higher to inject arbitrary web scripts. The injected scripts execute whenever a user accesses the affected page. The weakness is tracked under CWE-79.
Critical Impact
Authenticated contributors can store malicious JavaScript in Countdown widget attributes, enabling session theft, redirect attacks, and defacement against visitors and administrators who view affected pages.
Affected Products
- HT Mega – Absolute Addons For Elementor (free, WordPress) versions <= 2.8.1
- Hasthemes ht_mega plugin — Countdown widget component
- WordPress sites using HT Mega with contributor-or-higher accounts enabled
Discovery Timeline
- 2025-02-11 - CVE-2024-12599 published to NVD
- 2026-06-17 - Last updated in NVD database
Technical Details for CVE-2024-12599
Vulnerability Analysis
The vulnerability is a Stored XSS flaw in the Countdown widget shipped with HT Mega – Absolute Addons For Elementor. The plugin accepts user-supplied widget attributes from the Elementor editor and renders them into page markup without adequate sanitization or output escaping. An authenticated user with contributor privileges or higher can embed JavaScript payloads directly into widget attribute values. When any visitor loads a page containing the modified widget, the browser executes the attacker's script in the context of the site origin. This grants the attacker the ability to steal authenticated session cookies, perform actions on behalf of administrators, redirect users to attacker-controlled infrastructure, or deliver secondary payloads such as credential harvesters. The persistent nature of stored XSS makes exploitation reliable and does not require ongoing interaction from the attacker after injection.
Root Cause
The root cause is missing input sanitization on widget attributes submitted through the Elementor editor and missing output escaping when those attributes are rendered on the front end. The plugin treats attacker-controlled strings as safe markup rather than untrusted text. See the vendor change set for the specific files modified to add escaping routines.
Attack Vector
Exploitation requires an authenticated account with contributor-level permissions or above on a WordPress site running a vulnerable version of HT Mega. The attacker creates or edits a post containing the Countdown widget and injects a JavaScript payload into one of the widget attribute fields. The post is then saved and either published directly or submitted for review. When a reviewer, administrator, or front-end visitor loads the page, the browser parses and executes the embedded script. The attack vector is network-based and requires user interaction in the form of visiting the compromised page. No synthetic exploit code is published for this issue; refer to the Wordfence Vulnerability Report for additional analysis.
Detection Methods for CVE-2024-12599
Indicators of Compromise
- Countdown widget attribute values containing <script> tags, javascript: URIs, or event handlers such as onerror, onload, or onclick.
- Unexpected outbound requests from site visitors to attacker-controlled domains referenced by scripts loaded from post content.
- New or modified posts authored by contributor-level accounts that include Elementor Countdown widgets with unusual attribute payloads.
- Administrator session cookies appearing in access logs of external hosts shortly after viewing contributor-authored pages.
Detection Strategies
- Audit the WordPress database tables wp_posts and wp_postmeta for Countdown widget serialized data containing HTML or JavaScript tokens.
- Enable Content Security Policy (CSP) reporting to capture inline script violations on pages that render HT Mega widgets.
- Monitor WordPress audit logs for contributor and author accounts that create or edit posts shortly before anomalous front-end activity.
Monitoring Recommendations
- Alert on access to /wp-admin/post.php and /wp-admin/post-new.php by low-privilege roles when the request body contains script-like patterns.
- Track plugin version metadata across managed WordPress sites to confirm ht-mega-for-elementor is upgraded past 2.8.1.
- Review web server logs for abnormal referer chains originating from pages containing the Countdown widget.
How to Mitigate CVE-2024-12599
Immediate Actions Required
- Update HT Mega – Absolute Addons For Elementor to a version newer than 2.8.1 on every WordPress site where the plugin is installed.
- Review all existing posts and pages that use the Countdown widget for injected script content and remove any malicious payloads.
- Audit contributor, author, and editor accounts, rotate credentials for any suspicious accounts, and enforce multi-factor authentication.
Patch Information
The vendor addressed the issue in the release documented in WordPress plugin change set 3234495. The patch adds proper sanitization and output escaping to the Countdown widget attributes. Site operators should apply the update through the WordPress admin plugin manager or by deploying the latest package from the vendor. Additional context is available in the Wordfence Vulnerability Report.
Workarounds
- Temporarily disable the HT Mega plugin on sites that cannot update immediately, especially those permitting self-registration or contributor accounts.
- Restrict the Countdown widget to trusted roles only by removing contributor and author permissions to publish or submit posts containing Elementor widgets.
- Deploy a web application firewall (WAF) rule that blocks script tokens and event handler attributes within Elementor widget attribute payloads.
- Enforce a strict Content Security Policy that disallows inline script execution on front-end pages.
# Configuration example: update HT Mega via WP-CLI and verify version
wp plugin update ht-mega-for-elementor --path=/var/www/html
wp plugin get ht-mega-for-elementor --field=version --path=/var/www/html
# Optional: disable the plugin if an update is not yet available
wp plugin deactivate ht-mega-for-elementor --path=/var/www/html
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

