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

CVE-2025-22550: AddFunc Mobile Detect Stored XSS Vulnerability

CVE-2025-22550 is a stored cross-site scripting flaw in the AddFunc Mobile Detect WordPress plugin that enables attackers to inject malicious scripts. This article covers technical details, affected versions, and mitigation.

Published:

CVE-2025-22550 Overview

CVE-2025-22550 is a stored cross-site scripting (XSS) vulnerability in the AddFunc Mobile Detect WordPress plugin developed by Joe Rhoney. The flaw affects all plugin versions up to and including 3.1. Authenticated users with low-level privileges can inject persistent JavaScript payloads that execute in the browsers of visitors and administrators who load the affected pages. The issue is tracked under CWE-79 (Improper Neutralization of Input During Web Page Generation).

Critical Impact

An authenticated attacker can store malicious scripts through the plugin, leading to session hijacking, credential theft, and unauthorized administrative actions when other users view the injected content.

Affected Products

  • AddFunc Mobile Detect WordPress plugin (addfunc-mobile-detect) versions through 3.1
  • WordPress sites running any version of the plugin up to and including 3.1
  • Any site configuration exposing the vulnerable plugin fields to lower-privileged users

Discovery Timeline

  • 2025-01-07 - CVE-2025-22550 published to the National Vulnerability Database
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-22550

Vulnerability Analysis

The AddFunc Mobile Detect plugin fails to properly neutralize user-supplied input before rendering it inside web pages. An authenticated contributor-level or higher user can submit HTML and JavaScript payloads through plugin-controlled fields. The payload is stored in the WordPress database and later reflected without sanitization or output encoding when pages are rendered.

Stored XSS in a WordPress plugin extends the blast radius beyond the initial attacker session. Every visitor, including administrators, executes the payload in their authenticated browser context. Attackers commonly leverage this to steal session cookies, create rogue administrator accounts, or pivot to backend code execution through plugin or theme editors.

User interaction is required to trigger execution, and the scope changes across security boundaries because the injected script runs under the origin of the WordPress site itself.

Root Cause

The root cause is missing input validation and output encoding in the plugin's handling of user-supplied content. Fields intended to accept configuration text are not filtered with WordPress APIs such as wp_kses(), esc_html(), or esc_attr() before being written to the database or echoed to page templates. This allows raw <script> tags and event-handler attributes to persist and execute.

Attack Vector

Exploitation requires an authenticated account with permission to interact with the vulnerable plugin fields and a subsequent victim who loads the injected page. The attacker submits a crafted payload, waits for a higher-privileged user or site visitor to view the affected surface, and then leverages the executed script to perform actions in the victim's context. Refer to the Patchstack advisory for the disclosed technical details.

Detection Methods for CVE-2025-22550

Indicators of Compromise

  • Unexpected <script> tags, onerror, onload, or javascript: URIs stored in wp_options, wp_postmeta, or plugin-specific tables
  • New administrator accounts created shortly after a low-privileged user edited plugin settings
  • Outbound requests from visitor browsers to attacker-controlled domains after loading pages that render the plugin output

Detection Strategies

  • Audit database rows written by the addfunc-mobile-detect plugin for HTML markup and script fragments
  • Review WordPress access logs for POST requests to plugin administration endpoints from contributor or author accounts
  • Deploy a web application firewall rule set that flags XSS payloads in request bodies targeting the plugin

Monitoring Recommendations

  • Enable WordPress activity logging to correlate option or post edits with the user who submitted them
  • Alert on the creation of new administrator users, changes to user roles, and modifications to theme or plugin files
  • Monitor browser Content Security Policy (CSP) violation reports to catch script execution from unexpected inline sources

How to Mitigate CVE-2025-22550

Immediate Actions Required

  • Deactivate and remove the AddFunc Mobile Detect plugin until a patched release is confirmed
  • Rotate WordPress administrator credentials and invalidate active sessions if the plugin was in use
  • Review recently modified content, users, plugins, and themes for signs of tampering

Patch Information

No fixed version has been published as of the last NVD update. Versions through 3.1 remain vulnerable. Track the Patchstack advisory for updates and apply any vendor-released patch as soon as it becomes available.

Workarounds

  • Restrict plugin administration capabilities to trusted administrator accounts only
  • Deploy a web application firewall with XSS signatures in front of the WordPress site
  • Implement a strict Content Security Policy that disallows inline scripts and unapproved external origins
  • Replace the plugin with a maintained alternative for mobile device detection
bash
# Example: enforce a strict Content Security Policy in the WordPress site header
# Add to your web server or via a security plugin
Header set Content-Security-Policy "default-src 'self'; script-src 'self'; object-src 'none'; base-uri 'self'; frame-ancestors 'self'"

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

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.