Skip to main content

CVE-2025-4666: Zotpress WordPress Plugin XSS Vulnerability

CVE-2025-4666 is a stored cross-site scripting vulnerability in the Zotpress WordPress plugin allowing authenticated attackers to inject malicious scripts. This article covers the technical details, affected versions, 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-4666 Overview

CVE-2025-4666 is a stored Cross-Site Scripting (XSS) vulnerability affecting the Zotpress plugin for WordPress. The flaw exists in all versions up to and including 7.3.15. It stems from insufficient input sanitization and output escaping on the nickname parameter used by the plugin's admin account functionality. Authenticated attackers with Author-level privileges or higher can inject arbitrary JavaScript that executes in the browser of any user who accesses an affected page. The issue is tracked under CWE-79 and received a CVSS v3.1 base score of 6.4.

Critical Impact

Authenticated attackers with Author-level access can inject persistent JavaScript into WordPress pages, enabling session theft, administrative action hijacking, and defacement when administrators or other users browse the affected content.

Affected Products

  • Zotpress plugin for WordPress — all versions through 7.3.15
  • WordPress sites with Author-level or higher user accounts enabled
  • WordPress environments that expose Zotpress admin options forms to contributors

Discovery Timeline

  • 2025-06-11 - CVE-2025-4666 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-4666

Vulnerability Analysis

The vulnerability is a stored XSS flaw in Zotpress's admin account handling. Zotpress stores Zotero API account configuration, including a user-supplied nickname field, and later renders that value inside administrative pages. Because the plugin does not sanitize the input on save and does not escape the value on output, an attacker can embed HTML or JavaScript directly in the nickname. The payload persists in the WordPress database and executes every time an authenticated user loads a page that renders the account list. Public references point to lib/admin/admin.accounts.php and lib/admin/admin.options.form.php as the vulnerable code paths, with the fix applied in changeset 3308031.

Root Cause

The root cause is missing input validation and missing output encoding on the nickname parameter. The plugin accepts the field from an authenticated form submission and writes it to persistent storage without applying sanitize_text_field() or an equivalent filter. When the value is later echoed into HTML attributes and page content, it is not passed through esc_html(), esc_attr(), or wp_kses(). Any payload containing <script> tags or event handlers is rendered as live markup. See the Zotpress admin accounts source and the options form source for the pre-patch rendering logic.

Attack Vector

Exploitation requires an authenticated session with Author-level privileges or higher. The attacker submits a crafted nickname value through the Zotpress account configuration interface. The payload is stored server-side, so no user interaction is needed to deliver it. When an administrator or editor later visits the Zotpress admin page or any page that renders the stored nickname, the browser executes the injected script in the context of the WordPress site origin. This enables cookie theft where HttpOnly is not enforced, forced administrative requests via fetch() against wp-admin, and phishing overlays rendered inside the trusted dashboard.

No verified public proof-of-concept code is available. See the Wordfence vulnerability analysis for additional context.

Detection Methods for CVE-2025-4666

Indicators of Compromise

  • Zotpress account nickname values in wp_options or related plugin tables containing <script, onerror=, onload=, or javascript: substrings.
  • WordPress audit log entries showing Author-level or Contributor accounts modifying Zotpress account settings outside normal editorial workflows.
  • Unexpected outbound requests from administrator browsers to attacker-controlled domains shortly after loading Zotpress admin pages.

Detection Strategies

  • Query the WordPress database for Zotpress-related rows and grep stored nickname fields for HTML tags or JavaScript event handler patterns.
  • Review web server access logs for POST requests to Zotpress admin endpoints originating from non-administrator roles.
  • Deploy a web application firewall rule that inspects form submissions to Zotpress admin pages for script tags in the nickname parameter.

Monitoring Recommendations

  • Monitor WordPress user role assignments and flag any unexpected elevation to Author or higher.
  • Alert on changes to plugin configuration tables made by low-privilege authors.
  • Track browser Content Security Policy (CSP) violation reports from /wp-admin/ pages to surface injected inline scripts.

How to Mitigate CVE-2025-4666

Immediate Actions Required

  • Upgrade the Zotpress plugin to a version newer than 7.3.15 that includes changeset 3308031.
  • Audit all existing Zotpress account entries and remove any nickname values containing HTML or JavaScript.
  • Review the WordPress user list and revoke Author-level or higher access from accounts that do not require it.
  • Rotate administrator session cookies and credentials if indicators of exploitation are present.

Patch Information

The Zotpress maintainers addressed the vulnerability in WordPress plugin changeset 3308031, which adds sanitization and output escaping on the affected fields. Site operators should update through the WordPress plugin dashboard or by deploying the fixed release via their configuration management tooling. Confirm the installed version is greater than 7.3.15 after upgrade.

Workarounds

  • Restrict access to the Zotpress plugin by removing the capability from Author and Editor roles until the patched version is deployed.
  • Deploy a strict Content Security Policy on /wp-admin/ that disallows inline scripts to blunt payload execution.
  • Temporarily disable the Zotpress plugin if an immediate upgrade is not feasible and the plugin is not in active use.
bash
# Update Zotpress to the patched release via WP-CLI
wp plugin update zotpress
wp plugin get zotpress --field=version

# Audit stored nicknames for script payloads
wp db query "SELECT option_name, option_value FROM wp_options WHERE option_name LIKE '%zotpress%' AND option_value REGEXP '<script|onerror=|onload=|javascript:';"

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.