Skip to content

Disable biometric login after 24 hours of last password login #971

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

Merged
merged 3 commits into from
Sep 15, 2024

Conversation

yogeshpaliyal
Copy link
Owner

@yogeshpaliyal yogeshpaliyal commented Sep 15, 2024

Fixes #951

Add logic to disable biometric login if the user has not logged in via password in the last 24 hours.

  • UserSettings.kt

    • Add lastPasswordLoginTime attribute to track the last password login time.
  • BiometricPrompt.kt

    • Add logic to check lastPasswordLoginTime and disable biometric login if the last password login was more than 24 hours ago.
    • Add function updateLastBiometricLoginTime to update the last biometric login time.
  • AuthScreen.kt

    • Add logic to reset lastPasswordLoginTime when users log in via password.
  • SharedPreferenceUtils.kt

    • Add functions updateLastBiometricLoginTime and updateLastPasswordLoginTime to update the respective times in UserSettings.
  • ButtonBar.kt

    • Add logic to reset lastPasswordLoginTime when users log in via password.

For more details, open the Copilot Workspace session.

Fixes #951

Add logic to disable biometric login if the user has not logged in via password in the last 24 hours.

* **UserSettings.kt**
  - Add `lastPasswordLoginTime` attribute to track the last password login time.

* **BiometricPrompt.kt**
  - Add logic to check `lastPasswordLoginTime` and disable biometric login if the last password login was more than 24 hours ago.
  - Add function `updateLastBiometricLoginTime` to update the last biometric login time.

* **AuthScreen.kt**
  - Add logic to reset `lastPasswordLoginTime` when users log in via password.

* **SharedPreferenceUtils.kt**
  - Add functions `updateLastBiometricLoginTime` and `updateLastPasswordLoginTime` to update the respective times in `UserSettings`.

* **ButtonBar.kt**
  - Add logic to reset `lastPasswordLoginTime` when users log in via password.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/yogeshpaliyal/KeyPass/issues/951?shareId=XXXX-XXXX-XXXX-XXXX).
@yogeshpaliyal yogeshpaliyal merged commit cae27f6 into master Sep 15, 2024
3 checks passed
@yogeshpaliyal yogeshpaliyal deleted the disable-biometric branch September 15, 2024 11:19
github-actions bot pushed a commit that referenced this pull request Sep 15, 2024
…ord login (#971)

* Disable biometric login after 24 hours of last password login

Fixes #951

Add logic to disable biometric login if the user has not logged in via password in the last 24 hours.

* **UserSettings.kt**
  - Add `lastPasswordLoginTime` attribute to track the last password login time.

* **BiometricPrompt.kt**
  - Add logic to check `lastPasswordLoginTime` and disable biometric login if the last password login was more than 24 hours ago.
  - Add function `updateLastBiometricLoginTime` to update the last biometric login time.

* **AuthScreen.kt**
  - Add logic to reset `lastPasswordLoginTime` when users log in via password.

* **SharedPreferenceUtils.kt**
  - Add functions `updateLastBiometricLoginTime` and `updateLastPasswordLoginTime` to update the respective times in `UserSettings`.

* **ButtonBar.kt**
  - Add logic to reset `lastPasswordLoginTime` when users log in via password.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/yogeshpaliyal/KeyPass/issues/951?shareId=XXXX-XXXX-XXXX-XXXX).

* feat: fix changes

* feat: cleanup
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.

Disable Biometric every 24 hours
1 participant