All jobs / Mobile developer / Security
Mobile developer interview question · 5+ years
A security review asks what you assume about a rooted / jailbroken phone. What is a sane answer?
The strongest answer
The device is hostile: I protect tokens in hardware-backed storage, pin what we can rotate, minimise secrets on device, and I do not pretend root detection is a wall — I design so a stolen phone is a bounded incident
Why it works
Exactly. Hostile device, bounded blast radius, no faith in root theatre.
What a good answer covers
- Assume a hostile device.
- Hardware-backed keys, few secrets.
- Root detection is extra, not the control.
- Bound what a stolen phone can do.
Answers that fall short
- Close, but not the strongest: Root detection blocks everything; we are safe
Detection is a signal, not a wall. Serious people bypass it. - Weak: If they root it, that is their problem and not in our model
A stolen or shared phone is your incident too. - Red flag: I encrypt SharedPreferences with a key shipped in the APK
A key in the APK is not encryption you can claim.
Who gets asked this
More Security questions
- When does the org require certificate pinning?
- Growth wants a new attribution SDK that wants IDFA, a full photo dump, and its own WebView. What is the bar?
- When do you ask for camera permission?
- A junior wants to “add certificate pinning to everything” this week. What is the right first move?
- A partner API needs a secret key, and a teammate puts it in a constants file in the app. What do you say?
- You will pin your API. What else ships in the same change?
- Camera grant rate is poor and denied-forever is high. How do you work it?
- A pin mismatch will brick the app on a bad deploy. What is your break-glass?