[PR #3445] [MERGED] [PM-8137] Refactor FIDO 2 credential registration result object #16980

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

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/3445
Author: @SaintPatrck
Created: 7/11/2024
Status: Merged
Merged: 7/11/2024
Merged by: @SaintPatrck

Base: mainHead: PM-8137/refactor-passkey-create-result


📝 Commits (6)

  • 4618196 Refactor PublicKeyCredentialCreationOptions to match WebAuthn spec
  • 6cb5b3e Rename Fido2 credential registration result object
  • 55e7d2d Merge branch 'main' into PM-8137/refactor-passkey-create-result
  • fc97edd Improve test coverage
  • 65f9363 Merge branch 'main' into PM-8137/refactor-passkey-create-result
  • 9a2d826 Add comments about cancellation handling

📊 Changes

15 files changed (+270 additions, -91 deletions)

View changed files

📝 app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManager.kt (+3 -3)
📝 app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManagerImpl.kt (+5 -10)
app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/model/Fido2CreateCredentialResult.kt (+0 -23)
app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/model/Fido2RegisterCredentialResult.kt (+24 -0)
📝 app/src/main/java/com/x8bit/bitwarden/ui/autofill/fido2/manager/Fido2CompletionManager.kt (+3 -3)
📝 app/src/main/java/com/x8bit/bitwarden/ui/autofill/fido2/manager/Fido2CompletionManagerImpl.kt (+15 -5)
📝 app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditScreen.kt (+2 -2)
📝 app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModel.kt (+14 -13)
📝 app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingScreen.kt (+2 -2)
📝 app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingViewModel.kt (+13 -12)
📝 app/src/test/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManagerTest.kt (+3 -3)
📝 app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditScreenTest.kt (+5 -5)
📝 app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModelTest.kt (+86 -9)
📝 app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingScreenTest.kt (+1 -1)
📝 app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingViewModelTest.kt (+94 -0)

📄 Description

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-8137

📔 Objective

Rename passkey registration result object to better align terminology and reflect the registration process taking place.

Converted Error result to a data object and removed exception parameter.

Defined a Cancelled result object to represent explicit cancellation by the user. This result causes the initial credential selection screen to re-appear when the process is completed instead of reporting an error back to the relying party.

Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation or informed the documentation team

🦮 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

🔄 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/3445 **Author:** [@SaintPatrck](https://github.com/SaintPatrck) **Created:** 7/11/2024 **Status:** ✅ Merged **Merged:** 7/11/2024 **Merged by:** [@SaintPatrck](https://github.com/SaintPatrck) **Base:** `main` ← **Head:** `PM-8137/refactor-passkey-create-result` --- ### 📝 Commits (6) - [`4618196`](https://github.com/bitwarden/android/commit/46181968e69233806bc3a1111ce00040adcd8737) Refactor PublicKeyCredentialCreationOptions to match WebAuthn spec - [`6cb5b3e`](https://github.com/bitwarden/android/commit/6cb5b3e603f9eaca3ee62876f96e28f4f47403a5) Rename Fido2 credential registration result object - [`55e7d2d`](https://github.com/bitwarden/android/commit/55e7d2d7ae2ece18f4f15e0393b1886c229d973a) Merge branch 'main' into PM-8137/refactor-passkey-create-result - [`fc97edd`](https://github.com/bitwarden/android/commit/fc97edd7759bd0cc5635126ba993670833c75e74) Improve test coverage - [`65f9363`](https://github.com/bitwarden/android/commit/65f9363bec27dd57d8725df616fcb57fe6227b34) Merge branch 'main' into PM-8137/refactor-passkey-create-result - [`9a2d826`](https://github.com/bitwarden/android/commit/9a2d8265b5997a547e144176d1485268160ca8da) Add comments about cancellation handling ### 📊 Changes **15 files changed** (+270 additions, -91 deletions) <details> <summary>View changed files</summary> 📝 `app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManager.kt` (+3 -3) 📝 `app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManagerImpl.kt` (+5 -10) ➖ `app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/model/Fido2CreateCredentialResult.kt` (+0 -23) ➕ `app/src/main/java/com/x8bit/bitwarden/data/autofill/fido2/model/Fido2RegisterCredentialResult.kt` (+24 -0) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/autofill/fido2/manager/Fido2CompletionManager.kt` (+3 -3) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/autofill/fido2/manager/Fido2CompletionManagerImpl.kt` (+15 -5) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditScreen.kt` (+2 -2) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModel.kt` (+14 -13) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingScreen.kt` (+2 -2) 📝 `app/src/main/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingViewModel.kt` (+13 -12) 📝 `app/src/test/java/com/x8bit/bitwarden/data/autofill/fido2/manager/Fido2CredentialManagerTest.kt` (+3 -3) 📝 `app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditScreenTest.kt` (+5 -5) 📝 `app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModelTest.kt` (+86 -9) 📝 `app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingScreenTest.kt` (+1 -1) 📝 `app/src/test/java/com/x8bit/bitwarden/ui/vault/feature/itemlisting/VaultItemListingViewModelTest.kt` (+94 -0) </details> ### 📄 Description ## 🎟️ Tracking https://bitwarden.atlassian.net/browse/PM-8137 ## 📔 Objective Rename passkey registration result object to better align terminology and reflect the registration process taking place. Converted `Error` result to a `data object` and removed `exception` parameter. Defined a `Cancelled` result object to represent explicit cancellation by the user. This result causes the initial credential selection screen to re-appear when the process is completed instead of reporting an error back to the relying party. ## ⏰ Reminders before review - Contributor guidelines followed - All formatters and local linters executed and passed - Written new unit and / or integration tests where applicable - Used internationalization (i18n) for all UI strings - CI builds passed - Communicated to DevOps any deployment requirements - Updated any necessary documentation or informed the documentation team ## 🦮 Reviewer guidelines <!-- Suggested interactions but feel free to use (or not) as you desire! --> - 👍 (`:+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 --- <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-15 02:34:31 -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#16980