# Photo Gallery by Ays <= 6.9.3 - Missing Authorization to Unauthenticated User Enumeration via ays_gpg_author_user_search AJAX Action

- **ID:** WPSEC-2026-3997
- **Plugin:** Photo Gallery by Ays – Responsive Image Gallery (`gallery-photo-gallery`), https://wordpress.org/plugins/gallery-photo-gallery/
- **Affected versions:** from 5.0.6 before 6.9.4
- **Fixed in:** 6.9.4 (Update to 6.9.4 or later.)
- **Severity:** Medium 5.3 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N)
- **Weakness:** CWE-862
- **Usage among sites WPSec scans:** plugin Low, affected versions Low (as of 2026-11-26)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/gallery-photo-gallery
- **Fix released:** 2026-11-25
- **Published:** 2026-11-26
- **URL:** https://wpsec.com/vuln/WPSEC-2026-3997/

## Description

The Photo Gallery by Ays plugin for WordPress is vulnerable to unauthorized access of data via the ays_gpg_author_user_search AJAX action in all versions up to, and including, 6.9.3, due to a missing capability check and nonce verification on the ays_gpg_author_user_search() function, which was also registered for unauthenticated visitors through the wp_ajax_nopriv hook. This makes it possible for unauthenticated attackers to enumerate the site's users, retrieving their user IDs and display names, and to use wildcard searches matched against login names, email addresses and website URLs to infer those values.

## References

- https://wpsec.com/vuln/WPSEC-2026-3997/
- https://plugins.svn.wordpress.org/gallery-photo-gallery/tags/6.9.4/
- https://wordpress.org/plugins/gallery-photo-gallery/

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

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.
