CVE-2026-12982 Document Gallery < 5.1.1 - Reflected XSS via dg_generate_gallery
An attacker can execute arbitrary scripts in the victim's browser via a reflected XSS vulnerability in the Document Gallery WordPress plugin.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2026-12982?
CVE-2026-12982 is a medium-severity cross-site scripting vulnerability in Unknown Document Gallery, published on 27 Jul 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
The Document Gallery WordPress plugin before 5.1.1 does not properly sanitise and escape user input before reflecting it back in the response of an unauthenticated AJAX action, leading to a Reflected Cross-Site Scripting vulnerability which can be exploited against unauthenticated users.
Weakness: CWE-79
Which versions are affected by CVE-2026-12982?
How do I fix CVE-2026-12982?
No fix has been published for CVE-2026-12982 yet. Limit exposure of the affected software until one is available.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2026-12982 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-12982 exists.
Sources
Also known as GHSA-7prg-mrx9-fj7w.