Hardcoded API key exposes customer records
com.example.app
GET /v2/customers?limit=100 HTTP/1.1Host: api.example.comX-Api-Key: ak_7c1e…9d20HTTP/1.1 200 OK{"count":100,"data":[…]}# same key ships in every install- Impact
- The key ships inside every copy of the app. Anyone who unpacks it can read customer records through the API, and it cannot be rotated without updating every install.
- Fix
- Remove the key from the app. Authenticate each user with short-lived tokens, and limit what the API accepts from the mobile client.