Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-31858: CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') in craftcms cms

0
High
VulnerabilityCVE-2026-31858cvecve-2026-31858cwe-89
Published: Wed Mar 11 2026 (03/11/2026, 17:35:07 UTC)
Source: CVE Database V5
Vendor/Project: craftcms
Product: cms

Description

Craft is a content management system (CMS). The ElementSearchController::actionSearch() endpoint is missing the unset() protection that was added to ElementIndexesController in CVE-2026-25495. The exact same SQL injection vulnerability (including criteria[orderBy], the original advisory vector) works on this controller because the fix was never applied to it. Any authenticated control panel user (no admin required) can inject arbitrary SQL via criteria[where], criteria[orderBy], or other query properties, and extract the full database contents via boolean-based blind injection. Users should update to the patched 5.9.9 release to mitigate the issue.

AI-Powered Analysis

AILast updated: 03/11/2026, 18:49:34 UTC

Technical Analysis

CVE-2026-31858 is an SQL injection vulnerability classified under CWE-89, found in the Craft CMS content management system. The vulnerability exists in the ElementSearchController::actionSearch() endpoint, which fails to implement the unset() protection that was previously applied to the ElementIndexesController in an earlier vulnerability fix (CVE-2026-25495). This omission allows authenticated users with control panel access—without requiring administrative privileges—to inject malicious SQL code through parameters such as criteria[where], criteria[orderBy], and other query properties. The injection enables attackers to perform boolean-based blind SQL injection attacks, allowing them to extract sensitive data from the backend database. The affected versions range from 5.0.0-RC1 through 5.9.8, with the vulnerability patched in version 5.9.9. The CVSS v4.0 score is 8.7 (high), reflecting the vulnerability's network attack vector, low complexity, no required privileges beyond authentication, and no user interaction. The impact on confidentiality, integrity, and availability is high, as attackers can access and manipulate database contents. No known exploits are currently reported in the wild, but the vulnerability poses a significant risk to organizations using vulnerable Craft CMS versions.

Potential Impact

The SQL injection vulnerability allows attackers to extract, manipulate, or corrupt sensitive data stored in the Craft CMS database. Since the vulnerability can be exploited by any authenticated control panel user without admin privileges, insider threats or compromised low-privilege accounts can lead to full database disclosure. This can result in data breaches involving user information, content, and potentially credentials or configuration data. The integrity of the CMS data can be compromised, leading to defacement, unauthorized content changes, or further pivoting into the network. Availability could also be affected if attackers execute destructive SQL commands. Given Craft CMS's use in various industries for website management, the impact spans from reputational damage to regulatory penalties for data exposure. The ease of exploitation and high impact on confidentiality and integrity make this a critical concern for organizations relying on affected versions.

Mitigation Recommendations

Organizations should immediately upgrade Craft CMS installations to version 5.9.9 or later, where the vulnerability is patched. Until upgrading, restrict control panel access to trusted users only and enforce strong authentication mechanisms to reduce the risk of compromised accounts. Implement web application firewalls (WAFs) with custom rules to detect and block suspicious SQL injection patterns targeting criteria[where], criteria[orderBy], and similar parameters. Conduct thorough audits of user privileges to ensure that only necessary users have control panel access. Monitor logs for unusual query patterns or database access anomalies. Additionally, consider database-level protections such as limiting the database user permissions used by the CMS to minimize potential damage from SQL injection. Regularly review and test the CMS for security updates and vulnerabilities to maintain a secure environment.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-03-09T19:02:25.011Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 69b1b88b2f860ef9436021c1

Added to database: 3/11/2026, 6:46:35 PM

Last enriched: 3/11/2026, 6:49:34 PM

Last updated: 3/14/2026, 12:45:45 AM

Views: 13

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses