# ElasticPress <= 5.3.5 - Unauthenticated Stored Cross-Site Scripting via 'orderby' Parameter

- **ID:** WPSEC-2026-2999
- **Plugin:** ElasticPress (`elasticpress`), https://wordpress.org/plugins/elasticpress/
- **Affected versions:** from 4.4.0 before 5.3.6
- **Fixed in:** 5.3.6 (Update to 5.3.6 or later.)
- **Severity:** High 7.2 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N)
- **Weakness:** CWE-79
- **Usage among sites WPSec scans:** plugin Medium, affected versions Medium (as of 2026-11-12)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/elasticpress
- **Fix released:** 2026-11-11
- **Published:** 2026-11-12
- **URL:** https://wpsec.com/vuln/WPSEC-2026-2999/

## Description

The ElasticPress plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'orderby' parameter in all versions up to, and including, 5.3.5 due to insufficient output escaping of logged Elasticsearch error messages, query log values, and the recommended solutions built from them in the Failed Queries section of the Status Report. This makes it possible for unauthenticated attackers to trigger a failing search query whose error contains injected markup, storing arbitrary web scripts that execute whenever an administrator views the Failed Queries report.

## References

- https://wpsec.com/vuln/WPSEC-2026-2999/
- https://plugins.svn.wordpress.org/elasticpress/tags/5.3.6/
- https://wordpress.org/plugins/elasticpress/

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

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.
