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

Commit 38359725 authored by Max Bires's avatar Max Bires Committed by Gerrit Code Review
Browse files

Revert "Deprecate uses of Android Protected Confirmation"

Revert submission 2864688-apc-deprecate

Reason for revert: fix inadvertent partial deprecation

Reverted changes: /q/submissionid:2864688-apc-deprecate

Change-Id: I820e2916acfc711c6a092ac1371548f54fd170af
parent 3d9d1778
Loading
Loading
Loading
Loading
+0 −15
Original line number Original line Diff line number Diff line
@@ -59,10 +59,6 @@ public class AndroidProtectedConfirmation {


    /**
    /**
     * Requests keystore call into the confirmationui HAL to display a prompt.
     * Requests keystore call into the confirmationui HAL to display a prompt.
     * @deprecated Android Protected Confirmation had a low adoption rate among Android device
     *             makers and developers alike. Given the lack of devices supporting the
     *             feature, it is deprecated. Developers can use auth-bound Keystore keys
     *             as a partial replacement.
     *
     *
     * @param listener the binder to use for callbacks.
     * @param listener the binder to use for callbacks.
     * @param promptText the prompt to display.
     * @param promptText the prompt to display.
@@ -72,7 +68,6 @@ public class AndroidProtectedConfirmation {
     * @return one of the {@code CONFIRMATIONUI_*} constants, for
     * @return one of the {@code CONFIRMATIONUI_*} constants, for
     * example {@code KeyStore.CONFIRMATIONUI_OK}.
     * example {@code KeyStore.CONFIRMATIONUI_OK}.
     */
     */
    @Deprecated
    public int presentConfirmationPrompt(IConfirmationCallback listener, String promptText,
    public int presentConfirmationPrompt(IConfirmationCallback listener, String promptText,
                                         byte[] extraData, String locale, int uiOptionsAsFlags) {
                                         byte[] extraData, String locale, int uiOptionsAsFlags) {
        try {
        try {
@@ -89,16 +84,11 @@ public class AndroidProtectedConfirmation {


    /**
    /**
     * Requests keystore call into the confirmationui HAL to cancel displaying a prompt.
     * Requests keystore call into the confirmationui HAL to cancel displaying a prompt.
     * @deprecated Android Protected Confirmation had a low adoption rate among Android device
     *             makers and developers alike. Given the lack of devices supporting the
     *             feature, it is deprecated. Developers can use auth-bound Keystore keys
     *             as a partial replacement.
     *
     *
     * @param listener the binder passed to the {@link #presentConfirmationPrompt} method.
     * @param listener the binder passed to the {@link #presentConfirmationPrompt} method.
     * @return one of the {@code CONFIRMATIONUI_*} constants, for
     * @return one of the {@code CONFIRMATIONUI_*} constants, for
     * example {@code KeyStore.CONFIRMATIONUI_OK}.
     * example {@code KeyStore.CONFIRMATIONUI_OK}.
     */
     */
    @Deprecated
    public int cancelConfirmationPrompt(IConfirmationCallback listener) {
    public int cancelConfirmationPrompt(IConfirmationCallback listener) {
        try {
        try {
            getService().cancelPrompt(listener);
            getService().cancelPrompt(listener);
@@ -113,14 +103,9 @@ public class AndroidProtectedConfirmation {


    /**
    /**
     * Requests keystore to check if the confirmationui HAL is available.
     * Requests keystore to check if the confirmationui HAL is available.
     * @deprecated Android Protected Confirmation had a low adoption rate among Android device
     *             makers and developers alike. Given the lack of devices supporting the
     *             feature, it is deprecated. Developers can use auth-bound Keystore keys
     *             as a partial replacement.
     *
     *
     * @return whether the confirmationUI HAL is available.
     * @return whether the confirmationUI HAL is available.
     */
     */
    @Deprecated
    public boolean isConfirmationPromptSupported() {
    public boolean isConfirmationPromptSupported() {
        try {
        try {
            return getService().isSupported();
            return getService().isSupported();