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

Commit 8924e875 authored by Jeff Sharkey's avatar Jeff Sharkey
Browse files

Wire up lifecycle, send unlocked broadcast.

When the correct lock pattern is presented, ask the system to also
unlock credential-encrypted storage, if enabled.  The token passed
along is empty for now, but can be wired up to gatekeeper in the
future.

During each system boot, ask vold to lock all users keys to give us
a known starting state.  This also has the effect of chmod'ing away
any CE data when in emulation mode.

Define and send a new foreground broadcast when the CE storage is
unlocked for the first time.  Add stronger last-ditch checking for
encryption-awareness before starting an app.

Bug: 22358539
Change-Id: Id1f1bece96a2b4e6f061214d565d51c7396ab521
parent dfcd4c14
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -8344,6 +8344,7 @@ package android.content {
    field public static final java.lang.String ACTION_USER_FOREGROUND = "android.intent.action.USER_FOREGROUND";
    field public static final java.lang.String ACTION_USER_INITIALIZE = "android.intent.action.USER_INITIALIZE";
    field public static final java.lang.String ACTION_USER_PRESENT = "android.intent.action.USER_PRESENT";
    field public static final java.lang.String ACTION_USER_UNLOCKED = "android.intent.action.USER_UNLOCKED";
    field public static final java.lang.String ACTION_VIEW = "android.intent.action.VIEW";
    field public static final java.lang.String ACTION_VOICE_COMMAND = "android.intent.action.VOICE_COMMAND";
    field public static final deprecated java.lang.String ACTION_WALLPAPER_CHANGED = "android.intent.action.WALLPAPER_CHANGED";
+1 −0
Original line number Diff line number Diff line
@@ -8602,6 +8602,7 @@ package android.content {
    field public static final java.lang.String ACTION_USER_FOREGROUND = "android.intent.action.USER_FOREGROUND";
    field public static final java.lang.String ACTION_USER_INITIALIZE = "android.intent.action.USER_INITIALIZE";
    field public static final java.lang.String ACTION_USER_PRESENT = "android.intent.action.USER_PRESENT";
    field public static final java.lang.String ACTION_USER_UNLOCKED = "android.intent.action.USER_UNLOCKED";
    field public static final java.lang.String ACTION_VIEW = "android.intent.action.VIEW";
    field public static final java.lang.String ACTION_VOICE_COMMAND = "android.intent.action.VOICE_COMMAND";
    field public static final deprecated java.lang.String ACTION_WALLPAPER_CHANGED = "android.intent.action.WALLPAPER_CHANGED";
+1 −0
Original line number Diff line number Diff line
@@ -8344,6 +8344,7 @@ package android.content {
    field public static final java.lang.String ACTION_USER_FOREGROUND = "android.intent.action.USER_FOREGROUND";
    field public static final java.lang.String ACTION_USER_INITIALIZE = "android.intent.action.USER_INITIALIZE";
    field public static final java.lang.String ACTION_USER_PRESENT = "android.intent.action.USER_PRESENT";
    field public static final java.lang.String ACTION_USER_UNLOCKED = "android.intent.action.USER_UNLOCKED";
    field public static final java.lang.String ACTION_VIEW = "android.intent.action.VIEW";
    field public static final java.lang.String ACTION_VOICE_COMMAND = "android.intent.action.VOICE_COMMAND";
    field public static final deprecated java.lang.String ACTION_WALLPAPER_CHANGED = "android.intent.action.WALLPAPER_CHANGED";
+1 −1
Original line number Diff line number Diff line
@@ -3084,7 +3084,7 @@ public class ActivityManager {
    /** {@hide} */
    public static final int FLAG_OR_STOPPED = 1 << 0;
    /** {@hide} */
    public static final int FLAG_WITH_AMNESIA = 1 << 1;
    public static final int FLAG_AND_LOCKED = 1 << 1;

    /**
     * Return whether the given user is actively running.  This means that
+8 −0
Original line number Diff line number Diff line
@@ -2876,6 +2876,14 @@ public class Intent implements Parcelable, Cloneable {
    public static final String ACTION_USER_SWITCHED =
            "android.intent.action.USER_SWITCHED";

    /**
     * Broadcast Action: Sent when the credential-encrypted private storage has
     * become unlocked for the target user. This is only sent to registered
     * receivers, not manifest receivers.
     */
    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
    public static final String ACTION_USER_UNLOCKED = "android.intent.action.USER_UNLOCKED";

    /**
     * Broadcast sent to the system when a user's information changes. Carries an extra
     * {@link #EXTRA_USER_HANDLE} to indicate which user's information changed.
Loading