Loading lesson…
Level 1 · Apprentice0 XP
Where to keep preferences, data and secrets, and what an attacker can read.
Step 1 / 5
ProblemThe app saves the login token with AsyncStorage. It also ships with an API key in its code. Anyone with the phone, a backup or the app file can read both.
← → step
Before this: Server data with a cache
🛠️ Your turn
Reading is not the skill, doing is. Try for ten minutes before you open the hint. Getting stuck first is what makes the solution stick.
1.Search a project for where the login token is stored. If it is in AsyncStorage, move it to secure storage behind a small tokens module with save, read and clear. Then search the code for anything that looks like a secret key and list where each should live.