title: How to dismiss the BiometricPromptDialog after timeout in android?
body: <p>I'm creating an authentication service where the user must use the fingerprint sensor of the smartphone. I saw that android uses the BiometricPrompt APIs, but there's only one problem: I don't know how to set a timeout that dismisses the dialog after a certain amount of time (the dialog is always on utile the user cancels it or uses the fingerprint). Does anyone know how can I do it?</p>
  
  <p>I've tried modifying the executor parameter of the authentication method, but it seems that the executor is not called.</p>
  
  <p>EDIT</p>
  
  <p>I've updated the code using @Subham Naik advice</p>
  
  <pre><code>  timeOutHandler = new Handler();
          timeOutHandler.postDelayed(new Runnable() {
              @Override
              public void run() {
                  mBiometricManager.cancelAuthentication();
              }
          } ,4000);
  </code></pre>
  
  <p>But it works only on the first prompt: after the dialog goes off, the second time it stays on.</p>