craftcms/commerce
Affected
- introduced
5.0.0, fixed5.6.0(ecosystem)
Fixed versions
5.6.0
Fix
The export has no generic command for this ecosystem.
Advisory
Also known as: CVE-2026-32272
Craft Commerce hasVariant/hasProduct Blind SQL Injection
Overview
Craft Commerce’s ProductQuery::hasVariant and VariantQuery::hasProduct properties bypass the unset() blocklist added to ElementIndexesController in GHSA-2453-mppf-46cj.
The blocklist only strips top-level Yii2 Query properties (where, orderBy, etc.), but hasVariant and hasProduct pass
through untouched. Internally, these properties call Craft::configure() on a subquery without sanitization, re-introducing SQL injection via criteria[hasVariant][where]=INJECTED_SQL.
An authenticated control panel user can perform boolean-based blind SQL injection through the patched ElementIndexesController and extract arbitrary database contents.
Impact
Prerequisites
High Basis: The source's own band: HIGH
5.0.0, fixed 5.6.0 (ecosystem)5.6.0
The export has no generic command for this ecosystem.
Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0