{"id":"CVE-2026-31858","aliases":["CVE-2026-31858","GHSA-g7j6-fmwx-7vp8"],"related":[],"kind":"vulnerability","state":"published","title":"CraftCMS's `ElementSearchController` Affected by Blind SQL Injection","summary":"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.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"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.","source":"cvelist"},{"lang":"en","text":"The `ElementSearchController::actionSearch()` endpoint is missing the `unset()` protection that\nwas added to ElementIndexesController in [GHSA-2453-mppf-46cj](https://github.com/craftcms/cms/security/advisories/GHSA-2453-mppf-46cj).\n\nThe exact same SQL injection vulnerability (including `criteria[orderBy]`, the original advisory vector) works on this controller because the fix was never applied to it.\n\nAny authenticated control panel user (no admin required) can inject arbitrary SQL via `criteria[where]`,\n`criteria[orderBy]`, or other query properties, and extract the full database contents via boolean-based blind injection.\n\nUsers should update to the patched 5.9.9 release to mitigate the issue.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Craft es un sistema de gestión de contenido (CMS). El punto final ElementSearchController::actionSearch() carece de la protección unset() que se añadió a ElementIndexesController en CVE-2026-25495. Exactamente la misma vulnerabilidad de inyección SQL (incluyendo criteria[orderBy], el vector de aviso original) funciona en este controlador porque la solución nunca se le aplicó. Cualquier usuario autenticado del panel de control (no se requiere administrador) puede inyectar SQL arbitrario a través de criteria[where], criteria[orderBy], u otras propiedades de consulta, y extraer el contenido completo de la base de datos a través de inyección ciega basada en booleanos. Los usuarios deben actualizar a la versión 5.9.9 parcheada para mitigar el problema.","source":"nvd"}],"published":"2026-03-11T00:27:23.000Z","modified":"2026-06-17T10:34:38.727Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"}],"cwes":["CWE-89"],"affected":[{"ranges":[{"version":">= 5.0.0-RC1, <= 5.9.8","status":"affected"}],"vendor":"craftcms","product":"cms","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"5.0.0-RC1","status":"affected","fixed":"5.9.9"}],"ecosystem":"Packagist","package":"craftcms/cms","purl":"pkg:composer/craftcms/cms","source":"ghsa"},{"ranges":[{"status":"affected","introduced":"5.0.1","fixed":"5.9.9"},{"status":"affected","version":"5.0.0"},{"status":"affected","version":"5.0.0"}],"vendor":"craftcms","product":"craft_cms","cpe":"cpe:2.3:a:craftcms:craft_cms:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/craftcms/cms/security/advisories/GHSA-g7j6-fmwx-7vp8","tags":["patch","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/craftcms/cms/commit/e1a3dd669ae31491b86ad996e88a1d30d33d9a42","tags":["patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/craftcms/cms/security/advisories/GHSA-2453-mppf-46cj","tags":["web"],"sources":["ghsa"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-31858","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/craftcms/cms","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"total","date":"2026-03-12T14:01:02.909Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-31858","url":"https://www.cve.org/CVERecord?id=CVE-2026-31858","licence":"CVE Terms of Use","modified":"2026-03-12T14:01:14.728Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-g7j6-fmwx-7vp8","url":"https://github.com/advisories/GHSA-g7j6-fmwx-7vp8","licence":"CC-BY-4.0","modified":"2026-03-13T10:56:23.981Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-31858","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-31858","licence":"Public domain","modified":"2026-06-17T10:34:38.727Z"}],"updatedAt":"2026-11-25T22:59:15.757Z","epss":{"score":0.00398,"percentile":0.3613,"date":"2026-12-01T12:00:22.000Z"}}