I have an application which implements a DeviceAdminReceiver
. When the user attempts to unlock the device, I would like to be able to determine what method (e.g., PIN or fingerprint reader) was used.
The reason I would like to do this is because it is possible for fingerprint reader errors to exceed the threshold for failed unlocks as specified by the user's policy, and when this happens, the user's data will be wiped by the Device Manager. It is a poor user experience to lose your data because your hand brushed up against your phone in your bag while you were looking for something else. I would like to be able to be smarter about how fingerprint scanner failures are counted against the policy threshold vs. how PINs or password attempts are counted.
As far as I can tell, Android does not give me this information, but I thought I might ask the wider community on the chance I'm missing something.