Advisory Database
  • Advisories
  • Dependency Scanning
  1. composer
  2. ›
  3. craftcms/cms
  4. ›
  5. CVE-2026-25495

CVE-2026-25495: Craft CMS Vulnerable to SQL Injection in Element Indexes via `criteria[orderBy]`

February 9, 2026

The element-indexes/get-elements endpoint is vulnerable to SQL Injection via the criteria[orderBy] parameter (JSON body). The application fails to sanitize this input before using it in the database query. An attacker with Control Panel access can inject arbitrary SQL into the ORDER BY clause by omitting viewState[order] (or setting both to the same payload).

[!NOTE] The ORDER BY clause executes per row. SLEEP(1) on 10 rows = 10s delay.


References

  • github.com/advisories/GHSA-2453-mppf-46cj
  • github.com/craftcms/cms
  • github.com/craftcms/cms/commit/96c60d775c644ff0a0276da52fe29e11d4cd38d2
  • github.com/craftcms/cms/releases/tag/4.16.18
  • github.com/craftcms/cms/releases/tag/5.8.22
  • github.com/craftcms/cms/security/advisories/GHSA-2453-mppf-46cj
  • nvd.nist.gov/vuln/detail/CVE-2026-25495

Code Behaviors & Features

Detect and mitigate CVE-2026-25495 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions starting from 4.0.0-RC1 before 4.16.18, all versions starting from 5.0.0-RC1 before 5.8.22

Fixed versions

  • 5.8.22
  • 4.16.18

Solution

Upgrade to versions 4.16.18, 5.8.22 or above.

Impact 8.8 HIGH

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')

Source file

packagist/craftcms/cms/CVE-2026-25495.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Fri, 13 Feb 2026 00:18:37 +0000.