Summary
CVE-2026-39785 is a critical, unauthenticated SQL injection vulnerability in the Gmedia Photo Gallery WordPress plugin (plugin slug grand-media), developed by Serhii Pasyuk. The flaw allows a remote, unauthenticated attacker to inject malicious SQL via the plugin’s query handling, enabling blind extraction of data from the WordPress database. It affects all releases up to and including version 1.25.1 and carries a CVSS v3.1 base score of 9.3 (Critical).
Technical details
- Root cause: Improper neutralization of special elements used in an SQL command (CWE-89) within the plugin’s code, allowing user-supplied input to reach a SQL query without adequate sanitization or parameterization.
- Trigger conditions: No authentication or prior user interaction is required; the vulnerable functionality is reachable by any unauthenticated visitor to a site running the plugin.
- Attack vector: Network — the attacker sends crafted HTTP requests to the vulnerable WordPress site exposing the Gmedia Photo Gallery plugin.
- Exploitation technique: Classified as blind SQL injection (CAPEC-7), meaning exploitation typically relies on inferential techniques (e.g., boolean or time-based responses) rather than direct output of query results.
- Impact: High confidentiality impact (unauthorized read access to database contents, potentially including sensitive WordPress data such as user credentials/hashes) and low availability impact; integrity is not directly affected. The CVSS vector reflects a changed scope (S:C), indicating the vulnerability can affect resources beyond the vulnerable component itself.
Affected software
- Gmedia Photo Gallery WordPress plugin (slug:
grand-media), versions ≤ 1.25.1
Severity
- CVSS v3.1 Base Score: 9.3 (Critical)
- Vector:
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:L
Mitigation and recommended actions
- Immediate: As of this writing, no patched version beyond 1.25.1 (the last version confirmed to carry the vulnerability) has been publicly confirmed. Site administrators should monitor the WordPress.org plugin repository for an updated release and apply it as soon as it becomes available.
- If no patch is available:
- Deactivate or remove the Gmedia Photo Gallery plugin until a fix is released.
- Restrict or firewall access to the plugin’s front-end query endpoints at the web application firewall (WAF) layer, filtering requests containing SQL injection patterns.
- Monitor web server and database logs for anomalous query patterns, excessive error responses, or time-delay–based request patterns consistent with blind SQL injection probing.
- Limit database account privileges used by WordPress to the minimum required, reducing the blast radius of any successful injection.

