Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PM-7963] Fix vault timeout immediately on Android Fido2 autofill #3234

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

fedemkr
Copy link
Member

@fedemkr fedemkr commented May 10, 2024

Type of change

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

Objective

Fix vault timeout immediately on Android Fido2 autofill, where it was locking immediately after user unlocks because changing activity

Code changes

  • CredentialProviderSelectionActivity: Changed NoHistory to false so we can launch the MainActivity and return to this one. Added the activity launcher so we can launch MainActivity to unlock the vault after the user selects the cipher to autofill which confirms unlock on the callback.
  • Fido2GetAssertionUserInterface: Added _unlockVaultTcs so we can await until the user unlocks on immediate timeout vaults to ensure vault is unlocked for the Fido2 flow.
  • DeviceActionService: Added a new CredentialProviderConstants.Fido2CredentialNeedsUnlockingAgainBecauseImmediateTimeout to have a way to know after unlocking that is because of this scenario and then set the result back. Here a caveat is that we set vaultTimeoutService.DelayLockAndLogoutMs in order to maintain a time window of the vault unlocked for this flow. Otherwise it'll be immediately locked after the MainActivity is finished.

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

@fedemkr fedemkr requested a review from a team as a code owner May 10, 2024 20:56
Copy link
Contributor

@andrebispo5 andrebispo5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants