Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ad9714ba authored by Jigar Thakkar's avatar Jigar Thakkar Committed by Android (Google) Code Review
Browse files

Merge "Use allow_private_profile flag to guard private space API changes" into main

parents f3fe2d12 efa47fd0
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1551,7 +1551,7 @@ package android.hardware.biometrics {

  public static class BiometricPrompt.Builder {
    method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.TEST_BIOMETRIC, "android.permission.USE_BIOMETRIC_INTERNAL"}) public android.hardware.biometrics.BiometricPrompt.Builder setAllowBackgroundAuthentication(boolean);
    method @FlaggedApi("android.multiuser.enable_biometrics_to_unlock_private_space") @NonNull @RequiresPermission(anyOf={android.Manifest.permission.TEST_BIOMETRIC, "android.permission.USE_BIOMETRIC_INTERNAL"}) public android.hardware.biometrics.BiometricPrompt.Builder setAllowBackgroundAuthentication(boolean, boolean);
    method @FlaggedApi("android.os.allow_private_profile") @NonNull @RequiresPermission(anyOf={android.Manifest.permission.TEST_BIOMETRIC, "android.permission.USE_BIOMETRIC_INTERNAL"}) public android.hardware.biometrics.BiometricPrompt.Builder setAllowBackgroundAuthentication(boolean, boolean);
    method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.TEST_BIOMETRIC, "android.permission.USE_BIOMETRIC_INTERNAL"}) public android.hardware.biometrics.BiometricPrompt.Builder setAllowedSensorIds(@NonNull java.util.List<java.lang.Integer>);
  }

+3 −3
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@ import static android.hardware.biometrics.BiometricManager.Authenticators;
import static android.hardware.biometrics.Flags.FLAG_ADD_KEY_AGREEMENT_CRYPTO_OBJECT;
import static android.hardware.biometrics.Flags.FLAG_CUSTOM_BIOMETRIC_PROMPT;
import static android.hardware.biometrics.Flags.FLAG_GET_OP_ID_CRYPTO_OBJECT;
import static android.multiuser.Flags.FLAG_ENABLE_BIOMETRICS_TO_UNLOCK_PRIVATE_SPACE;
import static android.os.Flags.FLAG_ALLOW_PRIVATE_PROFILE;

import android.annotation.CallbackExecutor;
import android.annotation.DrawableRes;
@@ -529,7 +529,7 @@ public class BiometricPrompt implements BiometricAuthenticator, BiometricConstan

        /**
         * Remove {@link Builder#setAllowBackgroundAuthentication(boolean)} once
         * FLAG_ENABLE_BIOMETRICS_TO_UNLOCK_PRIVATE_SPACE is enabled.
         * FLAG_ALLOW_PRIVATE_PROFILE is enabled.
         *
         * @param allow If true, allows authentication when the calling package is not in the
         *              foreground. This is set to false by default.
@@ -538,7 +538,7 @@ public class BiometricPrompt implements BiometricAuthenticator, BiometricConstan
         * @return This builder
         * @hide
         */
        @FlaggedApi(FLAG_ENABLE_BIOMETRICS_TO_UNLOCK_PRIVATE_SPACE)
        @FlaggedApi(FLAG_ALLOW_PRIVATE_PROFILE)
        @TestApi
        @NonNull
        @RequiresPermission(anyOf = {TEST_BIOMETRIC, USE_BIOMETRIC_INTERNAL})