Skip to main content
Vulnerability Database/CVE-2025-10178

CVE-2025-10178: CM Business Directory XSS Vulnerability

CVE-2025-10178 is a stored XSS flaw in the CM Business Directory plugin for WordPress that lets authenticated attackers inject malicious scripts. This article covers the technical details, affected versions, security impact, and mitigation.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2025-10178 Overview

CVE-2025-10178 is a Stored Cross-Site Scripting (XSS) vulnerability in the CM Business Directory plugin for WordPress. The flaw affects all versions up to and including 1.5.2. It resides in the plugin's cmbd_featured_image shortcode, which fails to sanitize input and escape output on user-supplied attributes.

Authenticated attackers with contributor-level access or higher can inject arbitrary JavaScript into pages. The injected script executes in the browser of any visitor who accesses the affected page. The issue is tracked under CWE-79.

Critical Impact

Contributor-level users can persist arbitrary JavaScript that executes against site visitors and administrators, enabling session theft, admin account takeover, and site defacement.

Affected Products

  • CM Business Directory plugin for WordPress
  • All versions up to and including 1.5.2
  • Sites permitting Contributor role registration are the highest-risk deployments

Discovery Timeline

  • 2025-09-26 - CVE-2025-10178 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-10178

Vulnerability Analysis

The vulnerability lives in the plugin's business page shortcode handler at frontend/cm-business-directory-business-page-sc.php. The cmbd_featured_image shortcode accepts user-supplied attributes and renders them into the page output without proper sanitization or escaping.

Because the payload is stored server-side and rendered on subsequent page loads, the XSS is persistent rather than reflected. Any user who visits a page containing the malicious shortcode executes the attacker's script under the site's origin. Exploitation only requires a contributor account, which many WordPress sites grant liberally to guest authors and community contributors.

Root Cause

The root cause is missing input sanitization on shortcode attributes combined with unescaped output. WordPress provides helper functions such as sanitize_text_field(), esc_attr(), and esc_html() for exactly this scenario, but they are not applied to the vulnerable attribute path in the cmbd_featured_image handler. See the WordPress Plugin Code Reference for the affected code path.

Attack Vector

Exploitation requires network access to the WordPress site and authenticated access at Contributor role or higher. An attacker authors a post or page containing a cmbd_featured_image shortcode with a crafted attribute value that breaks out of the rendered HTML context and injects a script tag or event handler. When another user views the page, the browser executes the injected JavaScript in the site's origin, enabling cookie theft, forced administrative actions, or redirection to attacker-controlled infrastructure. Refer to the Wordfence Vulnerability Analysis for additional technical context.

Detection Methods for CVE-2025-10178

Indicators of Compromise

  • Post or page content containing [cmbd_featured_image ...] shortcodes with attribute values holding <script>, javascript:, or HTML event handlers such as onerror= or onload=.
  • Unexpected outbound requests from visitor browsers to unfamiliar domains after loading directory pages.
  • New or modified WordPress administrator accounts created shortly after a contributor authored content using the plugin's shortcodes.
  • Session cookies appearing in web server access logs for third-party endpoints referenced by injected scripts.

Detection Strategies

  • Query the wp_posts table for post_content containing cmbd_featured_image combined with HTML tags or on*= attributes.
  • Deploy a web application firewall rule that inspects rendered directory pages for inline <script> blocks that were not present in the theme.
  • Review WordPress audit logs for contributor-level accounts editing or publishing directory-related content.

Monitoring Recommendations

  • Enable a WordPress activity logging plugin to record post creation and editing by Contributor and Author roles.
  • Monitor Content Security Policy (CSP) violation reports for inline script execution on public directory pages.
  • Alert on creation of new administrative users, role escalations, or changes to wp_options outside of change windows.

How to Mitigate CVE-2025-10178

Immediate Actions Required

  • Update the CM Business Directory plugin to a version later than 1.5.2 as soon as the vendor releases a patched build.
  • Audit all posts and pages that use the cmbd_featured_image shortcode and remove any suspicious attribute content.
  • Restrict who can hold the Contributor role and require multi-factor authentication for all authenticated WordPress accounts.
  • Rotate administrator session cookies and reset passwords if injection is suspected.

Patch Information

At the time of NVD publication, all versions through 1.5.2 are affected. Monitor the WordPress Plugin Page and the WordPress Plugin Revision History for the fixed release, and apply it across all WordPress installations that use this plugin.

Workarounds

  • Deactivate the CM Business Directory plugin until a patched version is installed.
  • Remove or restrict use of the cmbd_featured_image shortcode via a must-use plugin that filters shortcode attributes through esc_attr().
  • Deploy a Content Security Policy that blocks inline scripts and restricts allowed script sources to reduce the impact of stored XSS.
  • Downgrade Contributor accounts that do not require publishing rights, and review recent posts authored by such accounts.
bash
# Configuration example: temporarily disable the plugin via WP-CLI
wp plugin deactivate cm-business-directory

# Search the database for suspicious shortcode usage
wp db query "SELECT ID, post_title FROM wp_posts \
  WHERE post_content LIKE '%cmbd_featured_image%' \
  AND (post_content LIKE '%<script%' OR post_content LIKE '%onerror=%');"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.