| Plugin Name | Envira Photo Gallery |
|---|---|
| Type of Vulnerability | Cross-Site Scripting (XSS) |
| CVE Number | CVE-2026-1236 |
| Urgency | Low |
| CVE Publish Date | 2026-03-05 |
| Source URL | CVE-2026-1236 |
Urgent: What WordPress Site Owners Need to Know About the Envira Photo Gallery Stored XSS (CVE-2026-1236)
Author: Hong Kong Security Expert | Date: 2026-03-05
If you run WordPress and use Envira Photo Gallery (Lite/Free or premium), read this now.
A stored Cross‑Site Scripting (XSS) vulnerability — CVE‑2026‑1236 — affects Envira Photo Gallery versions up to and including 1.12.3. An authenticated user with Author privileges (or higher) can inject a persistent XSS payload through the plugin’s REST API parameter named justified_gallery_theme. The vulnerability is fixed in Envira Photo Gallery 1.12.4.
The guidance below is pragmatic and direct — what to check, what to do now, and how to reduce risk while you patch. This is written from an operational security perspective typical of practitioners in Hong Kong: concise, action-focused, and suitable for site owners, agencies, and operations teams.
Quick summary (headlines)
- Vulnerability: Stored XSS via REST API parameter
justified_gallery_themein Envira Photo Gallery ≤ 1.12.3. - CVE: CVE‑2026‑1236. Patched in Envira Photo Gallery 1.12.4.
- Required privilege: authenticated user with at least the Author role.
- Impact: persistent XSS — injected script can run in visitors’ browsers (session theft, content modification, redirects, or pivoting through privileged user interactions).
- CVSS (reported): 5.9 (medium), but real risk increases on multi-author sites or where author accounts are less strictly controlled.
- Immediate actions: update to 1.12.4; if you cannot update immediately, apply virtual patching/WAF rules, restrict Author privileges, audit for injected payloads, and scan/clean any infected content.
Why this matters — stored XSS is dangerous
Stored XSS stores malicious script on the server (database, plugin settings, postmeta). Any user who views the affected page may execute that script. Unlike reflected XSS, stored XSS can persist and affect many users over time.
Even with a medium CVSS score, stored XSS can be leveraged to:
- Steal session cookies or tokens from editors and admins (if cookies are not HttpOnly).
- Modify site content (spam, malicious links, hidden SEO manipulation).
- Create backdoors or new admin users if privileged interfaces are accessible.
- Deliver malware to site visitors via injected scripts.
Because the vulnerability requires an Author or higher to submit the payload, sites with multiple editors, contributors, or guest authors are more exposed. Many teams grant Author-level access for convenience — that increases risk.
How the vulnerability works (high level)
- The plugin’s REST API accepts a parameter named
justified_gallery_theme. - The plugin fails to sanitize or escape this parameter properly when storing or rendering it.
- An authenticated Author writes a malicious value into
justified_gallery_themevia the REST API. - The malicious value is persisted and later output in a context where it executes as JavaScript in the browser (stored XSS).
- Any visitor viewing the gallery or an admin screen that renders the value may execute the injected script.
No proof‑of‑concept code is published here — act on detection and mitigation if you suspect impact.
Affected versions and remediation
- Affected: Envira Photo Gallery ≤ 1.12.3
- Patched in: Envira Photo Gallery 1.12.4
- CVE: CVE‑2026‑1236
Priority: update to 1.12.4 immediately. If update is not possible due to compatibility or staged rollout, implement virtual patching (WAF) and follow the checklist below.
Immediate steps — actionable checklist
- Update: Upgrade Envira Photo Gallery to 1.12.4 (or later). Test on staging first if necessary.
-
If you cannot update immediately — apply virtual patching/WAF:
- Block requests that attempt to set
justified_gallery_themeto suspicious content containingblocks in database rows where none should be present.
Final prioritized plan (practical)
- Update Envira Photo Gallery to 1.12.4 immediately.
- Apply short‑term WAF/virtual patch rules if you cannot update today.
- Audit and reduce Author+ privileges; enable 2FA for editors and admins.
- Run full malware and content scans; search the DB for script markers.
- Harden REST API access and implement CSP where feasible.
- Schedule regular scanning and security reviews.
Appendix: Useful commands and queries (examples)
# WP‑CLI DB search for suspicious postmeta wp db query "SELECT meta_id, post_id, meta_key, meta_value FROM wp_postmeta WHERE meta_value LIKE '%Adjust table prefixes if your installation does not use
wp_.If you want a tailored mitigation plan (custom WAF rules, virtual patch deployment, or guided cleanup), reply with your hosting environment type (shared, managed, VPS) and whether you have a staging environment — provide those details and I will give step‑by‑step guidance.
— Hong Kong Security Expert
- Block requests that attempt to set