CVE-2026-94462: Spree: Broken Access Control in `PATCH /api/v3/store/carts/:id/associate` (IDOR)
The Store API v3 endpoint PATCH /api/v3/store/carts/:id/associate binds a guest cart to the authenticated caller without verifying possession of that cart. It locates the cart by prefixed ID only — current_store.carts.where(user: [nil, current_user]).find_by_prefix_id!(params[:id]) — and omits the authorize!(:update, @cart, cart_token) check that every other action in the controller performs via CartResolvable. Because prefixed IDs are a reversible Sqids encoding of the auto-increment primary key (obfuscation, not a token), an authenticated customer can name arbitrary guest cart IDs, take them over, and read the checkout addresses stored on them. This is broken access control / IDOR, reachable by any low-privilege registered user.
References
- github.com/advisories/GHSA-4825-p4xm-pcf2
- github.com/spree/spree/commit/8834230a1f47bb5988f23f45dbd162776cf592bd
- github.com/spree/spree/commit/af0d1a2d582a60d179de65b7d3ea024cb26426a8
- github.com/spree/spree/pull/14314
- github.com/spree/spree/releases/tag/v5.4.4
- github.com/spree/spree/releases/tag/v5.5.4
- github.com/spree/spree/security/advisories/GHSA-4825-p4xm-pcf2
- nvd.nist.gov/vuln/detail/CVE-2026-94462
Code Behaviors & Features
Detect and mitigate CVE-2026-94462 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →