[PM-39455] Set Upgrade Tokens for Organizations - #8158
Conversation
Add OrganizationUser.V2UpgradeToken and write it during a V1 to V2 upgrade rotation, so an organization admin can unwrap the V2 user key through account recovery and update the account recovery key without prompting the member. A manual rotation always logs the user out, so it never persists a token and clears any token left over from an earlier upgrade.
ce7d47f to
bc9a62a
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8158 +/- ##
===========================================
+ Coverage 15.10% 67.53% +52.42%
===========================================
Files 1417 2315 +898
Lines 61422 100520 +39098
Branches 4901 9044 +4143
===========================================
+ Hits 9279 67885 +58606
+ Misses 51978 30350 -21628
- Partials 165 2285 +2120 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🤖 Bitwarden Claude Code ReviewOverall Assessment: APPROVE Reviewed the addition of Code Review Details
|
JimmyVo16
left a comment
There was a problem hiding this comment.
Just one question about the database column naming. DBOps will probably have a stronger opinion on the topic, but other than that, it looks good from the AC side.
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-39455
📔 Objective
Add
OrganizationUser.V2UpgradeTokenand write it during a V1 to V2 upgrade rotation, so an organization admin can unwrap the V2 user key through account recovery and update the account recovery key without prompting the member (tackled separately in later PRs).A manual rotation always logs the user out, so it never persists a token and clears any token left over from an earlier upgrade.
📸 Screenshots