# Envira Gallery <= 1.17.1 - Authenticated (Contributor+) Stored Cross-Site Scripting via Lightbox Gallery Links

- **ID:** WPSEC-2026-4448
- **Plugin:** Envira Gallery – Image Photo Gallery, Albums, Video Gallery, Slideshows & More (`envira-gallery-lite`), https://wordpress.org/plugins/envira-gallery-lite/
- **Affected versions:** all versions before 1.17.2
- **Fixed in:** 1.17.2 (Update to 1.17.2 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-03)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/envira-gallery-lite
- **Fix released:** 2026-12-01
- **Published:** 2026-12-03
- **URL:** https://wpsec.com/vuln/WPSEC-2026-4448/

## Description

The Envira Gallery plugin for WordPress is vulnerable to Stored Cross-Site Scripting via lightbox gallery links in all versions up to, and including, 1.17.1. This is due to the gallery init script binding the lightbox to every element on the page with the predictable envira-gallery-<id> class, and the lightbox building its gallery group from every link on the page that shares the gallery's rel value. As a result, links the plugin did not create can supply their own href, title and data-envirabox options (such as HTML content) to the lightbox. This makes it possible for authenticated attackers, with contributor-level access and above, to place such links in post content next to an embedded gallery and inject arbitrary web scripts that execute when a user browses the gallery in the lightbox.

## References

- https://wpsec.com/vuln/WPSEC-2026-4448/
- https://plugins.svn.wordpress.org/envira-gallery-lite/tags/1.17.2/
- https://wordpress.org/plugins/envira-gallery-lite/

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

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.
