Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-106097 Overview
CVE-2026-106097 is a SQL injection vulnerability in the Code Snippets WordPress plugin before version 3.10.0. The plugin fails to sanitize and escape a user-supplied parameter in its snippet-migration import endpoints. These endpoints are accessible to any user holding site-administration capabilities. On WordPress Multisite networks, subsite Administrators who are not network Super Admins can abuse this flaw. Attackers can perform UNION-based SQL injection against shared network tables. The result is cross-tenant disclosure of network-wide data, including other users' password hashes.
Critical Impact
A subsite Administrator on a WordPress Multisite network can execute UNION-based SQL injection to disclose network-wide data, including password hashes belonging to other sites and the network Super Admin.
Affected Products
- Code Snippets WordPress plugin versions prior to 3.10.0
- WordPress Multisite deployments running vulnerable plugin versions
- Shared hosting environments with multiple subsite Administrators
Discovery Timeline
- 2026-10-09 - CVE-2026-106097 published to NVD
- 2026-10-09 - Last updated in NVD database
Technical Details for CVE-2026-106097
Vulnerability Analysis
The vulnerability resides in the snippet-migration import endpoints of the Code Snippets plugin. These endpoints accept user-supplied input that is incorporated directly into a SQL query without sanitization or escaping. The capability check restricts the endpoint to users with site-administration privileges. On a single-site WordPress install, this restriction limits exposure to trusted administrators. On a WordPress Multisite network, the trust boundary breaks because subsite Administrators share the same database tables as other subsites and the network Super Admin.
An attacker exploiting this flaw can craft a UNION-based SQL injection payload. The payload reads arbitrary rows from shared Multisite tables such as wp_users and wp_usermeta. Disclosed data includes password hashes, session tokens, and application passwords for users outside the attacker's assigned subsite.
Root Cause
The root cause is improper neutralization of special elements used in a SQL command [CWE-89]. The import handler concatenates a request parameter into a SQL statement rather than using parameterized queries or wpdb::prepare(). Additionally, the plugin's authorization model assumes site-administration capability equates to full database trust, which is invalid in a Multisite context.
Attack Vector
An authenticated subsite Administrator sends a crafted request to the vulnerable snippet-migration import endpoint. The malicious parameter contains a UNION SELECT clause targeting the shared wp_users table. The database returns rows from the UNION query in the plugin's response, exposing credentials network-wide. Exploitation requires valid Administrator credentials on at least one subsite but no interaction from other users. See the WPScan Vulnerability Details for technical specifics.
Detection Methods for CVE-2026-106097
Indicators of Compromise
- Requests to Code Snippets import or migration endpoints containing SQL keywords such as UNION, SELECT, FROM, or information_schema
- Unexpected admin-ajax.php or REST API calls originating from subsite Administrator accounts referencing the Code Snippets plugin
- Database query logs showing UNION queries against wp_users or wp_usermeta initiated by the web server user
- Password reset activity or unexplained logins for Super Admin accounts following subsite Administrator activity
Detection Strategies
- Enable WordPress query logging and alert on UNION SELECT patterns within requests tied to the Code Snippets plugin paths
- Deploy a web application firewall rule inspecting POST bodies to snippet-import endpoints for SQL metacharacters
- Audit wp_users access patterns for queries that read rows outside the current subsite's blog_id context
Monitoring Recommendations
- Monitor plugin version inventory across the Multisite network and alert on installations below 3.10.0
- Track administrative actions from subsite Administrators, especially import and migration operations
- Review web server access logs for anomalous response sizes from Code Snippets endpoints, which can indicate data exfiltration
How to Mitigate CVE-2026-106097
Immediate Actions Required
- Update the Code Snippets plugin to version 3.10.0 or later on every site in the Multisite network
- Audit the list of subsite Administrators and remove accounts that no longer require elevated privileges
- Force password resets for all network users if exploitation is suspected, as password hashes may have been exfiltrated
- Rotate secrets stored in wp-config.php including AUTH_KEY and related salts
Patch Information
The maintainers addressed the vulnerability in Code Snippets version 3.10.0. The fix introduces proper sanitization and parameterized queries for the affected snippet-migration import endpoints. Administrators should apply the update through the WordPress plugin management interface or via WP-CLI across all network sites.
Workarounds
- Temporarily deactivate the Code Snippets plugin network-wide until the patched version is deployed
- Restrict snippet-import endpoints at the web server or WAF layer so only network Super Admins can access them
- On high-trust Multisite deployments, limit snippet management to Super Admins by removing site-administration capability from subsite Administrators
# Update Code Snippets across every site in a WordPress Multisite network
wp plugin update code-snippets --network
# Verify the installed version meets or exceeds the patched release
wp plugin get code-snippets --field=version
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

