MetaMask / MetaMask/metamask-mobile
iOS keychain persistence
- Dominant language
- TypeScript
- Stars
- 3k
- Forks
- 1.7k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 669
Description
### What is this about?
Sentry logging is showing an increase in iOS keychain persistence issues. Where the users password and other metadata seem to be wiped from the keychain. Below is a common stack trace and error flow for these iOS users.
```
Error: Login/ handleVaultCorruption: getVaultFromBackup failed to retrieve vault
at ?anon_0_ (app/components/Views/Login/index.tsx:321:24)
at next (native)
at asyncGeneratorStep (node_modules/@babel/runtime/helpers/asyncToGenerator.js:3:17)
at _next (node_modules/@babel/runtime/helpers/asyncToGenerator.js:17:27)
at tryCallOne (app:///main.jsbundle:1:1181)
at anonymous (app:///main.jsbundle:1:1875)
```
### Scenario
_No response_
### Design
_No response_
### Technical Details
_No response_
### Threat Modeling Framework
_No response_
### Acceptance Criteria
_No response_
### Stakeholder review needed before the work gets merged
- [ ] Engineering (needed in most cases)
- [ ] Design
- [ ] Product
- [ ] QA (automation tests are required to pass before merging PRs but not all changes are covered by automation tests - please review if QA is needed beyond automation tests)
- [ ] Security
- [ ] Legal
- [ ] Marketing
- [ ] Management (please specify)
- [ ] Other (please specify)
### References
_No response_
Contributor guide
Research direction
Start with app/components/Views/Login/index.tsx around line 321, where the reported stack trace shows handleVaultCorruption calling getVaultFromBackup. Trace the iOS keychain persistence and backup flow, then reproduce the reported vault-loss scenario. Done should demonstrate that the affected password and metadata remain recoverable and that the failure path is covered by verification.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, react-native, typescript
- Domain
- mobile, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 28/100