# Shopify.com Web Cache Deception vulnerability leads to personal information and CSRF tokens leakage

Path-confusion cache deception on help.shopify.com cached authenticated 404 pages containing PII and CSRF tokens, retrievable unauthenticated via curl.

- Payout: $800
- Severity: low
- Program: Shopify
- Found by: golim
- Disclosed: 2021-10-21
- Write-up quality: 7/10
- Original: https://hackerone.com/reports/1271944
- Library page: https://bugbountylibrary.com/r/h1%3A1271944
- Tags: area:web domain:web impact:data-leak impact:pii-leak kind:bounty platform:hackerone sev:low tech:cdn technique:recon vuln:cache-deception vuln:csrf vuln:info-disclosure

**Target:** help.shopify.com and hatchful.shopify.com behind Cloudflare CDN
**Root cause:** CDN classified responses as cacheable based on the .css extension in the URL path rather than the actual Content-Type, so authenticated 404 pages were cached and served to unauthenticated users.
**Steps:**
1. Pick random string e.g. `abcdefg`
2. Compose `https://help.shopify.com/es/manual/your-account/copyright-and-trademark/abcdefg.css`
3. Victim (authenticated) opens the URL in browser, triggering cache of the 404 page with their PII
4. Attacker requests same URL with `curl` (no cookies) and reads cached response
5. Extract name, username, email, profile picture, CSRF token from source
6. Variant: `https://hatchful.shopify.com/furniture-logo-maker%25%32%46random.css` leaks API key
**How found:** Systematically tested sites for web cache deception using path-confusion techniques, appending random string plus .css extension to authenticated endpoints and observing whether personalized 404 pages were cached.
**Exploitation:** Social-engineer victim into visiting the crafted .css-suffixed URL while authenticated; CDN caches the personalized 404 page; attacker fetches the same URL unauthenticated from the same cache region to retrieve PII and CSRF token.
**Escalation:** Leaked CSRF token enables bypassing CSRF protection for follow-on state-changing requests; hatchful variant leaks API keys.
**Insight:** Authenticated 404/error pages often embed user context (name, email, CSRF token) and are frequently cached by CDNs keyed on file extension; test error paths with .css/.js suffixes and encoded slashes (%25%32%46) across cache regions.

## Proof of concept (copied exactly from the original report)

**Path-confusion URL caching authenticated 404 page**

```
https://help.shopify.com/es/manual/your-account/copyright-and-trademark/<RANDOM_STRING>.css`

This URL will be interpreted as a CSS file from the cache server, resulting in the web page being cached (with the personal information of the authenticated user embedded). Your website, instead, returns a 404 not found error page that includes some user's personal information.

Please find all vulnerable URLs in attachment F1384114

## Steps to Reproduce

1. Create a random string: e.g., `abcdefg`
2. Compose the URL as explained before: e.g., `https://help.shopify.com/es/manual/your-account/copyright-and-trademark/abcdefg.css
```

**Encoded-slash URL leaking API key**

```
https://hatchful.shopify.com/furniture-logo-maker%25%32%46random.css
```

