[PR #3049] [MERGED] [PM-6539] Fix Autofill Extension TDE without MP flow #52206

Closed
opened 2026-05-01 16:04:21 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/3049
Author: @fedemkr
Created: 3/1/2024
Status: Merged
Merged: 3/5/2024
Merged by: @fedemkr

Base: mainHead: vault/pm-6539/tde-no-mp-autofill-fix


📝 Commits (2)

  • a9b20de PM-6539 Fix Autofill Extension TDE without MP updating PromptSSO to work in MAUI and also Generator view. WebAuthenticator copied with UIWindow gotten as it was in Xamarin forms to work. Also fix one NRE on state migration.
  • 304e583 PM-6539 Remove unnecessary using

📊 Changes

15 files changed (+790 additions, -43 deletions)

View changed files

📝 src/Core/Core.csproj (+2 -0)
📝 src/Core/Pages/Accounts/LoginSsoPage.xaml.cs (+1 -0)
📝 src/Core/Pages/Accounts/LoginSsoPageViewModel.cs (+15 -0)
📝 src/Core/Services/Logging/DebugLogger.cs (+2 -4)
📝 src/Core/Services/StateMigrationService.cs (+10 -8)
src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticator.ios.cs (+244 -0)
src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticator.shared.cs (+188 -0)
src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticatorResult.cs (+152 -0)
src/Core/Utilities/WebAuthenticatorMAUI/WebUtils.cs (+126 -0)
📝 src/iOS.Autofill/CredentialProviderViewController.cs (+4 -3)
📝 src/iOS.Autofill/LockPasswordViewController.cs (+19 -12)
📝 src/iOS.Core/Controllers/BaseLockPasswordViewController.cs (+21 -12)
📝 src/iOS.Core/Controllers/LoginAddViewController.cs (+2 -1)
📝 src/iOS.Extension/LoadingViewController.cs (+3 -2)
📝 src/iOS.ShareExtension/LoadingViewController.cs (+1 -1)

📄 Description

Type of change

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

Objective

Fix Autofill iOS Extension when using TDE without MP flow.

Note: I also fixed one NRE on the state migration from 6 to 7, also same happening on Generator view on iOS extension. Additionally, WebAuthenticator was copied and adapted from MAUI Essentials to get the current UIWindow as in Xamarin Essentials.

Code changes

  • BaseLockPasswordViewController: Updating PromptSSO view controller creation to be like in MAUI.
  • LoginAddViewController: Fixed generator view controller creation to be like in MAUI.
  • StateMigrationService: Fix NRE if state is null
  • LoginSSOViewModel: Fix to use workaround for iOS Extension on the WebAuthenticator
  • WebAuthenticator: MAUI Essentials copy of WebAuthenticator adapted to get the current UIWIndow as it was being done in Xamarin Essentials to work in iOS Extensions.

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/3049 **Author:** [@fedemkr](https://github.com/fedemkr) **Created:** 3/1/2024 **Status:** ✅ Merged **Merged:** 3/5/2024 **Merged by:** [@fedemkr](https://github.com/fedemkr) **Base:** `main` ← **Head:** `vault/pm-6539/tde-no-mp-autofill-fix` --- ### 📝 Commits (2) - [`a9b20de`](https://github.com/bitwarden/android/commit/a9b20de256c4ef98447a8280a488fd12dd942f53) PM-6539 Fix Autofill Extension TDE without MP updating PromptSSO to work in MAUI and also Generator view. WebAuthenticator copied with UIWindow gotten as it was in Xamarin forms to work. Also fix one NRE on state migration. - [`304e583`](https://github.com/bitwarden/android/commit/304e583978eb05fb55d6b9490808688a28d9c6a9) PM-6539 Remove unnecessary using ### 📊 Changes **15 files changed** (+790 additions, -43 deletions) <details> <summary>View changed files</summary> 📝 `src/Core/Core.csproj` (+2 -0) 📝 `src/Core/Pages/Accounts/LoginSsoPage.xaml.cs` (+1 -0) 📝 `src/Core/Pages/Accounts/LoginSsoPageViewModel.cs` (+15 -0) 📝 `src/Core/Services/Logging/DebugLogger.cs` (+2 -4) 📝 `src/Core/Services/StateMigrationService.cs` (+10 -8) ➕ `src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticator.ios.cs` (+244 -0) ➕ `src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticator.shared.cs` (+188 -0) ➕ `src/Core/Utilities/WebAuthenticatorMAUI/WebAuthenticatorResult.cs` (+152 -0) ➕ `src/Core/Utilities/WebAuthenticatorMAUI/WebUtils.cs` (+126 -0) 📝 `src/iOS.Autofill/CredentialProviderViewController.cs` (+4 -3) 📝 `src/iOS.Autofill/LockPasswordViewController.cs` (+19 -12) 📝 `src/iOS.Core/Controllers/BaseLockPasswordViewController.cs` (+21 -12) 📝 `src/iOS.Core/Controllers/LoginAddViewController.cs` (+2 -1) 📝 `src/iOS.Extension/LoadingViewController.cs` (+3 -2) 📝 `src/iOS.ShareExtension/LoadingViewController.cs` (+1 -1) </details> ### 📄 Description ## Type of change - [X] Bug fix - [ ] 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--> Fix Autofill iOS Extension when using TDE without MP flow. _Note: I also fixed one NRE on the state migration from 6 to 7, also same happening on Generator view on iOS extension. Additionally, `WebAuthenticator` was copied and adapted from MAUI Essentials to get the current `UIWindow` as in Xamarin Essentials._ ## 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--> * **BaseLockPasswordViewController:** Updating PromptSSO view controller creation to be like in MAUI. * **LoginAddViewController:** Fixed generator view controller creation to be like in MAUI. * **StateMigrationService:** Fix NRE if `state` is `null` * **LoginSSOViewModel:** Fix to use workaround for iOS Extension on the `WebAuthenticator` * **WebAuthenticator:** MAUI Essentials copy of `WebAuthenticator` adapted to get the current `UIWIndow` as it was being done in Xamarin Essentials to work in iOS Extensions. ## 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-05-01 16:04:21 -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#52206