Severity by source
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:L
Contributor account required so PR:L; network, low-complexity, no interaction; SQLi reads database (C:H) with limited write potential (I:L) and no availability impact.
Primary rating from Vendor (patchstack).
CVSS VectorVendor: patchstack
Lifecycle Timeline
1DescriptionCVE.org
Contributor SQL Injection in Gallery <= 4.7.8 versions.
AnalysisAI
SQL injection in the WordPress 'Gallery' plugin (gallery-plugin) through version 4.7.8 lets authenticated low-privilege users (Contributor role and above) inject crafted SQL via plugin-handled parameters, exposing the WordPress database. Tracked as CVE-2026-57642 (CWE-89) and reported by Patchstack, the flaw carries a CVSS 3.1 base score of 8.5; there is no public exploit identified at time of analysis and it is not listed in CISA KEV. A Contributor account is required, which limits exploitation to sites that allow self-registration or otherwise provision contributor-level access.
Technical ContextAI
The affected component is the BestWebSoft-style 'Gallery' plugin for WordPress, a PHP-based extension that manages image galleries through the WordPress admin and database layer. The root cause is CWE-89 (improper neutralization of special elements in an SQL command): user-controllable input reaches a database query without proper parameterization/escaping, allowing the attacker to alter query structure. WordPress plugins typically build queries against the shared MySQL/MariaDB backend using $wpdb; when developer code concatenates request parameters instead of using $wpdb->prepare(), an attacker with access to the vulnerable gallery endpoint can manipulate the resulting query. No CPE strings were supplied in the input, so the precise affected configuration is identified only by the plugin slug 'gallery-plugin' and the version ceiling of 4.7.8.
RemediationAI
Upgrade the Gallery plugin to a release later than 4.7.8 as soon as the vendor publishes a fixed version; the input data does not contain an exact patched version number, so confirm the fixed release directly via the Patchstack advisory (https://patchstack.com/database/wordpress/plugin/gallery-plugin/vulnerability/wordpress-gallery-plugin-4-7-8-sql-injection-vulnerability?_s_id=cve) - patch status is best described as no specific vendor-released fix version identified in the available data. Because exploitation requires a Contributor account, the most effective compensating controls are to disable open user registration (Settings > General > 'Anyone can register') or lower the default new-user role below Contributor, and to audit existing Contributor/Author accounts for untrusted users; the trade-off is reduced ability for legitimate guest authors to self-register. As an additional layer, deploy a WordPress WAF (for example Patchstack's virtual patch or equivalent ruleset) to block SQL injection patterns against the plugin endpoints, accepting the usual risk of false positives on legitimate gallery requests. If the plugin is not essential, deactivating and removing it eliminates the exposure entirely.
More in Wordpress Plugin
View allThe Backup Migration plugin for WordPress is vulnerable to Remote Code Execution in all versions up to, and including, 1
The Hash Form - Drag & Drop Form Builder plugin for WordPress is vulnerable to arbitrary file uploads due to missing fil
Authentication bypass in the LiteSpeed Cache WordPress plugin (versions prior to 6.5.0.1) allows unauthenticated remote
The Simple File List plugin for WordPress through version 4.2.2 contains an unauthenticated remote code execution vulner
The SureTriggers WordPress plugin through version 1.0.82 contains a privilege escalation vulnerability that allows unaut
The Ninja Forms plugin before 2.9.42.1 for WordPress allows remote attackers to conduct PHP object injection attacks via
The Business Directory Plugin - Easy Listing Directories for WordPress plugin for WordPress is vulnerable to time-based
SQL injection in the NotificationX WordPress plugin (versions up to and including 2.8.2) allows unauthenticated remote a
The POST SMTP Mailer - Email log, Delivery Failure Notifications and Best Mail SMTP for WordPress plugin for WordPress i
The MasterStudy LMS WordPress Plugin - for Online Courses and Education plugin for WordPress is vulnerable to union base
The Email Subscribers by Icegram Express plugin for WordPress is vulnerable to SQL Injection via the ‘hash’ parameter in
Remote code execution in the WP Query Console WordPress plugin (versions up to and including 1.0) by Ajit Bohra allows u
Same weakness CWE-89 – SQL Injection
View allShare
External POC / Exploit Code
Leaving vuln.today
EUVD-2026-39757
GHSA-pj5w-v4fq-q95p