我们如何在FingerGenManager中测试KeyGenParameterSpec.Builder中的invalidatedByBiometricEnrollment

时间:2018-12-12 20:28:41

标签: android

我指的是https://github.com/googlesamples/android-FingerprintDialog

invalidatedByBiometricEnrollment的角色还不够清楚。

if {@code false} is passed, the created key will not
be invalidated even if a new fingerprint is enrolled.
The default value is {@code true}, so passing
{@code true} doesn't change the behavior
(the key will be invalidated if a new fingerprint is
enrolled.). Note that this parameter is only valid if
the app works on Android N developer preview.

我们测试了几种情况。我们根据true中不同的false / invalidatedByBiometricEnrollment值进行了测试。是的,它们都产生相同的行为。

在启动应用程序之前,系统已经包含Finger 1记录

  1. 该应用只能识别手指1。

尝试通过“设置”将Finger 2添加到系统中

  1. 关闭应用程序。
  2. 通过“设置”将手指2添加到系统中
  3. 启动该应用程序。无论invalidatedByBiometricEnrollment的值如何,应用程序都可以识别手指1和手指2。

尝试通过“设置”从系统中删除Finger 1

  1. 关闭应用程序。
  2. 通过“设置”将手指1从系统中移出
  3. 启动该应用程序。无论invalidatedByBiometricEnrollment的值如何,应用程序都只能识别手指2。

有人针对不同值invalidatedByBiometricEnrollment进行测试吗?

0 个答案:

没有答案