ObliviOS Developer portal Project site

Home / Decisions / ADR-114

Treat a decoy registration whose user no longer exists as "no decoy" when routing a wrong PIN, and leave upstream's "Already tried that PIN" duplicate-guess handling…

Accepted, recorded 29 September 2026.

Decision
ADR-114
Date
2026-09-29
Status
AcceptedAccepted
Part
Duress Unlock

1Decision

Treat a decoy registration whose user no longer exists as "no decoy" when routing a wrong PIN, and leave upstream's "Already tried that PIN" duplicate-guess handling exactly as it is. Ship the fix in stallion's 2026092802 candidate and later.

2Why and evidence

Owner-reported on stallion and lynx: after a wrong PIN the screen turns off, and repeating the same PIN shows "Already tried that PIN". Root cause, from stallion logcat and its locksettings.db: decoy_profile_state stayed 0:10 after the decoy user was removed with pm remove-user, so the first wrong PIN was verified against user 10.

That user has no protector, its LskfIdentifier reads as a special credential, and SoftwareRateLimiter.writeStats threw IllegalArgumentException: Unknown special user id 10 out of checkCredential into SystemUI, which crashed and restarted (six identical am_crash entries in one log buffer). A repeated identical wrong guess is a duplicate: no hardware write, no crash, and the bouncer shows the upstream message.

That message and the duplicate handling are unmodified upstream code and a rate-limit mitigation, so they are deliberately untouched. The fix is one guard in DecoyProfileHelper.maybeRouteToDecoy: a missing or partial decoy user takes the same path as no decoy at all, including the equivalent-cost dummy check, so timing matches a device with no decoy. No new permission, IPC endpoint or API.

3Consequences

Real branch frameworks/base sovereignos-2026091900-r2 commit c013345b2161; package patch credential/duress-unlock-decoy/patches/frameworks-base/0011 with root cause and evidence in that package's SOURCE.md.

Hardware evidence on stallion (user build 2026092802): all three core Duress scenarios still pass, and with the decoy removed and the registration left in place, five verifications of user 0, none of user 10, no am_crash, no SystemUI restart.

Limits, stated plainly: no unit test exists for DecoyProfileHelper; on a user build the registration cannot be read, so its persistence rests on the same procedure leaving 0:10 earlier the same day; not tested on lynx; the registration is still not cleared when the decoy user is removed.

4Review when

lynx rebuild (unverified there until then); a user-removal hook that clears the registration (this guard then becomes defence in depth); any proposal to change duplicate-guess handling needs its own ADR.

Read from docs/governance/decision-log.md, entry ADR-114.