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

Fixed an issue can activate the faceid switch without a passcode #1595

Merged
merged 4 commits into from
May 16, 2024

Conversation

charliescheer
Copy link
Contributor

Fix

Currently there is an issue where you can activate the FaceID/Biometry lock switch for Simplenote without entering a passcode. We do not permit this, and the biometry doesn't actually activate, but default setting changes and the switch appears like it is active. This PR fixes that.

Steps to repro on trunk:

  1. with PIN code and biometry disabled go to the settings view
  2. enable the faceID switch without putting in a passcode
  3. Swipe up and close out of the app without dealing with the modal.
  4. Relaunch the app and go back to settings, you will see that the biometry switch is active, but it shouldn't be.

Test

  1. with PIN code and biometry disabled go to the settings view
  2. enable the faceID switch without putting in a passcode
  3. Swipe up and close out of the app without dealing with the modal.
  4. Relaunch the app and go back to settings, you will see that the biometry switch is not active

Confirm you can set a passcode and activate biometry.

Review

(Required) Add instructions for reviewers. For example:

Only one developer is required to review these changes, but anyone can perform the review.

Release

(Required) Add a concise statement to RELEASE-NOTES.txt if the changes should be included in release notes. Include details about updating the notes in this section. For example:

RELEASE-NOTES.txt was updated in b2f88d with:

Fixed an issue can activate the faceid switch without a passcode

@charliescheer charliescheer added this to the 4.52 milestone May 15, 2024
@charliescheer charliescheer self-assigned this May 15, 2024
@dangermattic
Copy link
Collaborator

1 Error
🚫 PR requires at least one label.

Generated by 🚫 Danger

Copy link
Contributor

@jleandroperez jleandroperez left a comment

Choose a reason for hiding this comment

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

:shipit:

@@ -87,6 +87,7 @@ extension SPSettingsViewController: PinLockSetupControllerDelegate {
func pinLockSetupControllerDidComplete(_ controller: PinLockSetupController) {
SPTracker.trackSettingsPinlockEnabled(true)
dismissPresentedViewController()
SPPinLockManager.shared.shouldUseBiometry = biometrySwitch.isOn
Copy link
Contributor

Choose a reason for hiding this comment

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

I think you don't really need to check on biometrySwitch.isOn, it'll always be true, if you got into this spot?

If so, perhaps, for readability, we could set it to = true?

@charliescheer charliescheer merged commit 9c747bd into trunk May 16, 2024
2 of 7 checks passed
@charliescheer charliescheer deleted the charlie/1327/faceid-activated-without-passcode branch May 16, 2024 17:30
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

3 participants