# Comments – wpDiscuz <= 7.7.0 - Authenticated (Subscriber+) Stored Cross-Site Scripting via Display Name in User Mentions

- **ID:** WPSEC-2026-4705
- **Plugin:** Comments – wpDiscuz (`wpdiscuz`), https://wordpress.org/plugins/wpdiscuz/
- **Affected versions:** from 7.0.0 before 7.8.0
- **Fixed in:** 7.8.0 (Update to 7.8.0 or later.)
- **Severity:** Medium 6.4 (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N)
- **Weakness:** CWE-79
- **Usage among sites WPSec scans:** plugin Low, affected versions Low (as of 2026-12-05)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/wpdiscuz
- **Fix released:** 2026-12-04
- **Published:** 2026-12-05
- **URL:** https://wpsec.com/vuln/WPSEC-2026-4705/

## Description

The wpDiscuz plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the user display name in @mentions in all versions up to, and including, 7.7.0, due to insufficient output escaping in the userMentioning() function. It inserts the mentioned user's display name and profile URL without escaping and replaces mentions anywhere in the comment HTML, including inside attribute values such as a link's href. This makes it possible for authenticated attackers, with subscriber-level access and above, to set a display name containing an attribute-breaking payload and mention themselves in a comment link. The injected web scripts then run for moderators and visitors viewing the comment. User mentioning is enabled by default.

## References

- https://wpsec.com/vuln/WPSEC-2026-4705/
- https://plugins.svn.wordpress.org/wpdiscuz/tags/7.8.0/
- https://wordpress.org/plugins/wpdiscuz/

Source: WPSec, https://wpsec.com/vuln/WPSEC-2026-4705/

License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Free to use, share and adapt, also commercially, if you credit WPSec and link to this advisory.
