# Gmedia Photo Gallery <= 1.25.1 - Cross-Site Request Forgery to Arbitrary Gmedia Term Deletion via Module Preset Restore

- **ID:** WPSEC-2026-1042
- **Plugin:** Gmedia Photo Gallery (`grand-media`), https://wordpress.org/plugins/grand-media/
- **Affected versions:** all versions before 1.25.2
- **Fixed in:** 1.25.2 (Update to 1.25.2 or later.)
- **Severity:** Medium 5.4 (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:L)
- **Weakness:** CWE-352
- **Usage among sites WPSec scans:** plugin Medium, affected versions Low (as of 2026-10-15)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/grand-media
- **Fix released:** 2026-10-14
- **Published:** 2026-10-15
- **URL:** https://wpsec.com/vuln/WPSEC-2026-1042/

## Description

The Gmedia Photo Gallery plugin for WordPress is vulnerable to Cross-Site Request Forgery via the 'module_preset_restore_original' action of the Gmedia Galleries admin page in all versions up to, and including, 1.25.1, due to missing nonce validation and no check on the term the 'preset_default' parameter points to. This makes it possible for unauthenticated attackers to delete any Gmedia term (module presets, galleries, albums, categories or tags), together with its linked WordPress post, via a forged request. The attacker has to trick a site administrator, or another user granted the Gmedia gallery management capability, into performing an action such as clicking on a link.

## References

- https://wpsec.com/vuln/WPSEC-2026-1042/
- https://plugins.svn.wordpress.org/grand-media/tags/1.25.2/
- https://wordpress.org/plugins/grand-media/

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

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.
