[PR #2655] [MERGED] [PM-1208] Add TDE flows for new users #23087

Closed
opened 2026-04-16 23:15:02 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/2655
Author: @andrebispo5
Created: 8/2/2023
Status: Merged
Merged: 8/3/2023
Merged by: @andrebispo5

Base: feature/pm-1029-tde-loginHead: auth/pm-1208-newuser


📝 Commits (10+)

  • 08d8663 [PM-1208] Create new user on SSO. Logout if not password is setup or has pending admin auth request.
  • 267dc66 [PM-1208] Fix new user UserKey decryption.
  • eab8050 [PM-1208] Add new user continue to vault logic. Auto enroll user on continue.
  • 931f9e0 [PM-1208] Trust device only if needed
  • 2a1b10f code format
  • 42eab2e PR fix
  • 275a05f Code refactor
  • 19b4f97 [PM-1208] PR fix
  • 8850404 [PM-1208] PR Fix, backwards compatibility
  • d2c3132 [PM-1208] Null check

📊 Changes

15 files changed (+271 additions, -70 deletions)

View changed files

📝 src/App/Pages/Accounts/LockPageViewModel.cs (+18 -0)
📝 src/App/Pages/Accounts/LoginApproveDevicePage.xaml (+1 -1)
📝 src/App/Pages/Accounts/LoginApproveDevicePage.xaml.cs (+13 -2)
📝 src/App/Pages/Accounts/LoginApproveDeviceViewModel.cs (+24 -11)
📝 src/App/Pages/Accounts/LoginSsoPageViewModel.cs (+42 -13)
📝 src/App/Resources/AppResources.Designer.cs (+9 -0)
📝 src/App/Resources/AppResources.resx (+3 -0)
📝 src/Core/Abstractions/IAuthService.cs (+1 -0)
📝 src/Core/Abstractions/IKeyConnectorService.cs (+3 -1)
src/Core/Abstractions/IPasswordResetEnrollmentService.cs (+12 -0)
📝 src/Core/Models/Domain/AccountDecryptionOptions.cs (+2 -0)
📝 src/Core/Services/AuthService.cs (+37 -38)
📝 src/Core/Services/KeyConnectorService.cs (+40 -2)
src/Core/Services/PasswordResetEnrollmentService.cs (+62 -0)
📝 src/Core/Utilities/ServiceContainer.cs (+4 -2)

📄 Description

Type of change

  • Bug fix
  • New feature development
  • Tech debt (refactoring, code cleanup, dependency upgrades, etc)
  • Build/deploy pipeline (DevOps)
  • Other

Objective

Add necessary login flows to new users after SSO login using TDE.

Code changes

src/App/Pages/Accounts/LockPageViewModel.cs:
Log user out if they have a pending auth request or if they have TDE enabled and don't have a master password nor PIN or Biometrics

src/App/Pages/Accounts/LoginSsoPageViewModel.cs:
Auto check if the users pending auth request has been accepted.

src/Core/Services/PasswordResetEnrollmentService.cs
Service containing new user org auto enrolment.

Screenshots

New user first time login:

https://github.com/bitwarden/mobile/assets/4648522/08c3e558-f290-4d95-b9f6-9873593af2aa

New user after auto enrolment:

https://github.com/bitwarden/mobile/assets/4648522/6a3104f9-0da5-4d84-ae12-cb9872668895

Before you submit

  • Please check for formatting errors (dotnet format --verify-no-changes) (required)
  • Please add unit tests where it makes sense to do so (encouraged but not required)
  • If this change requires a documentation update - notify the documentation team
  • If this change has particular deployment requirements - notify the DevOps team

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/2655 **Author:** [@andrebispo5](https://github.com/andrebispo5) **Created:** 8/2/2023 **Status:** ✅ Merged **Merged:** 8/3/2023 **Merged by:** [@andrebispo5](https://github.com/andrebispo5) **Base:** `feature/pm-1029-tde-login` ← **Head:** `auth/pm-1208-newuser` --- ### 📝 Commits (10+) - [`08d8663`](https://github.com/bitwarden/android/commit/08d86639559bbd49fd257450713ff871ba737d03) [PM-1208] Create new user on SSO. Logout if not password is setup or has pending admin auth request. - [`267dc66`](https://github.com/bitwarden/android/commit/267dc66b76f8dc3d3607bb2a1357beef1d1e7a6e) [PM-1208] Fix new user UserKey decryption. - [`eab8050`](https://github.com/bitwarden/android/commit/eab80508730d552ecbb46014b6e6bb03313e9abf) [PM-1208] Add new user continue to vault logic. Auto enroll user on continue. - [`931f9e0`](https://github.com/bitwarden/android/commit/931f9e07cfb3ab3020ca76a6f6e157e27d25a442) [PM-1208] Trust device only if needed - [`2a1b10f`](https://github.com/bitwarden/android/commit/2a1b10fc4502f4bf00bdf947d340be0cd336d798) code format - [`42eab2e`](https://github.com/bitwarden/android/commit/42eab2e8bf9c0fa15d557d683f776f96337b0b30) PR fix - [`275a05f`](https://github.com/bitwarden/android/commit/275a05f6b0386328deb84f0ccd7f89acc1d9f829) Code refactor - [`19b4f97`](https://github.com/bitwarden/android/commit/19b4f97b5c6904551dbcf9a4ad25ec6ffa3555a4) [PM-1208] PR fix - [`8850404`](https://github.com/bitwarden/android/commit/8850404f834aac1b2626c6f4f2905280d8875a44) [PM-1208] PR Fix, backwards compatibility - [`d2c3132`](https://github.com/bitwarden/android/commit/d2c3132c52269cb7f0828a2a5b389b06de45dbc2) [PM-1208] Null check ### 📊 Changes **15 files changed** (+271 additions, -70 deletions) <details> <summary>View changed files</summary> 📝 `src/App/Pages/Accounts/LockPageViewModel.cs` (+18 -0) 📝 `src/App/Pages/Accounts/LoginApproveDevicePage.xaml` (+1 -1) 📝 `src/App/Pages/Accounts/LoginApproveDevicePage.xaml.cs` (+13 -2) 📝 `src/App/Pages/Accounts/LoginApproveDeviceViewModel.cs` (+24 -11) 📝 `src/App/Pages/Accounts/LoginSsoPageViewModel.cs` (+42 -13) 📝 `src/App/Resources/AppResources.Designer.cs` (+9 -0) 📝 `src/App/Resources/AppResources.resx` (+3 -0) 📝 `src/Core/Abstractions/IAuthService.cs` (+1 -0) 📝 `src/Core/Abstractions/IKeyConnectorService.cs` (+3 -1) ➕ `src/Core/Abstractions/IPasswordResetEnrollmentService.cs` (+12 -0) 📝 `src/Core/Models/Domain/AccountDecryptionOptions.cs` (+2 -0) 📝 `src/Core/Services/AuthService.cs` (+37 -38) 📝 `src/Core/Services/KeyConnectorService.cs` (+40 -2) ➕ `src/Core/Services/PasswordResetEnrollmentService.cs` (+62 -0) 📝 `src/Core/Utilities/ServiceContainer.cs` (+4 -2) </details> ### 📄 Description ## Type of change - [ ] Bug fix - [X] New feature development - [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) - [ ] Build/deploy pipeline (DevOps) - [ ] Other ## Objective <!--Describe what the purpose of this PR is. For example: what bug you're fixing or what new feature you're adding--> Add necessary login flows to new users after SSO login using TDE. ## Code changes <!--Explain the changes you've made to each file or major component. This should help the reviewer understand your changes--> <!--Also refer to any related changes or PRs in other repositories--> **src/App/Pages/Accounts/LockPageViewModel.cs:** Log user out if they have a pending auth request or if they have TDE enabled and don't have a master password nor PIN or Biometrics **src/App/Pages/Accounts/LoginSsoPageViewModel.cs:** Auto check if the users pending auth request has been accepted. **src/Core/Services/PasswordResetEnrollmentService.cs** Service containing new user org auto enrolment. ## Screenshots <!--Required for any UI changes. Delete if not applicable--> New user first time login: https://github.com/bitwarden/mobile/assets/4648522/08c3e558-f290-4d95-b9f6-9873593af2aa New user after auto enrolment: https://github.com/bitwarden/mobile/assets/4648522/6a3104f9-0da5-4d84-ae12-cb9872668895 ## Before you submit - Please check for formatting errors (`dotnet format --verify-no-changes`) (required) - Please add **unit tests** where it makes sense to do so (encouraged but not required) - If this change requires a **documentation update** - notify the documentation team - If this change has particular **deployment requirements** - notify the DevOps team --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-16 23:15:03 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#23087