[PM-3483] Remove migrateKeyForNeverLockIfNeeded
Logic
#8953
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Type of change
Objective
This helps fix a bug in MV3 where you could force stop the service worker from
chrome://serviceworker-internals
and then when the service worker restarted we would runVaultTimeoutService.init
and in doing that we'd also runmigrateKeyForNeverLockIfNeeded
. Since the service worker restarting doesn't mean we lose our memory storage data, my user will still have a master key in memory. This trickedCryptoService.isLegacyUser
into thinking that I was a legacy user and that I should be logged out. But this user isn't a legacy user and they don't use never lock. This meant that you could reopen your popup and you would be logged out when you would have expected to be logged in still.Likely, there is logic wrong in these checks, since it would falsely report me as legacy when I was not, but this is also logic we had marked for deletion 6 months ago.
After deleting this code I can stop the service worker and open the popup back open still logged in.
Before you submit