-
Notifications
You must be signed in to change notification settings - Fork 53
PM-13367: Fix TDE logout could bypass MP approval #1140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
No New Or Fixed Issues Found |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1140 +/- ##
==========================================
+ Coverage 89.36% 89.38% +0.01%
==========================================
Files 688 688
Lines 43702 43734 +32
==========================================
+ Hits 39056 39091 +35
+ Misses 4646 4643 -3 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving with some questions that I believe it's fine but raising just in case
🎟️ Tracking
PM-13367
📔 Objective
This fixes a bug where after logging out and then back into an account with TDE and a master password, if you switch accounts on the vault unlock screen you can get into the newly added TDE account without having to confirm your master password.
The root cause of this was that
VaultTimeoutService
was usingStateService.getAccountIdOrActiveId(_:)
to get the active user ID, but this does some validation on the user ID and the user ID was already deleted prior to this. I ended up reversing the order of this so the account is ultimately deleted last. However, this caused an issue with the database publishers getting updates as the user's data is deleted from the database. At that point the vault is locked so if any decryption operations are attempted, it would log an error. Instead of deleting data table-by-table, I updated the batch delete to delete everything before merging the changes back into the context.⏰ Reminders before review
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes