authpass / biometric_storage

Flutter plugin to store data behind biometric authentication (ie. fingerprint)
https://pub.dev/packages/biometric_storage
MIT License
177 stars 104 forks source link

FaceId popup not show when call read() #68

Open skyphantomhz opened 2 years ago

skyphantomhz commented 2 years ago

Hi

I'm build on real iOS device. I can see FaceId popup when i call storage.read() at first time. But i call storage.read() at second times it auto return value from storage without FaceId verification.

So can i force FaceId verification when i call storage.read()

luckyrat commented 2 years ago

I think my changes in https://github.com/authpass/biometric_storage/pull/70 might resolve this issue but I don't have a device with FaceId support to test it myself.

I've only tested with authenticationValidityDurationSeconds set to > 0 but if it doesn't work for <= 0, I suspect that setting that to 1 second would be a reasonable workaround for all realistic use-cases.

For the record, with the current package version you would most likely find that if you wait for 10 minutes before calling storage.read(), you'll be prompted again. This is because the LAContext is being reused indefinitely but there appears to be a hidden fixed limit of 10 minutes for the validity of the context before iOS decides it needs to re-authenticate. That limit may vary across different iOS versions but definitely is the case in iOS 12 with TouchId.

skyphantomhz commented 2 years ago

Thanks for your response.

I'm looking forward new version.

barilki commented 2 years ago

@skyphantomhz same.

vikashrathore081 commented 1 year ago

I am facing the same issue.Anyone got solution for this?

abdallah-odeh commented 1 year ago

Facing the same issue here, it works perfectly on android but it has a weird behavior in the iOS it's been a long time since this issue is opened and yet, no solution??

nainamaharjan commented 1 year ago

Is it solved ?