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

Unverified Commit 5286ff9a authored by Kevin F. Haggerty's avatar Kevin F. Haggerty
Browse files

Merge tag 'android-security-11.0.0_r56' of...

Merge tag 'android-security-11.0.0_r56' of https://android.googlesource.com/platform/frameworks/base into staging/lineage-18.1_merge_android-security-11.0.0_r56

Android Security 11.0.0 Release 56 (8528208)

* tag 'android-security-11.0.0_r56' of https://android.googlesource.com/platform/frameworks/base:
  Disallow PAP authentication when MPPE is requested
  limit TelecomManager#registerPhoneAccount to 10; api doc update
  [rvc] RESTRICT AUTOMERGE Add finalizeWorkProfileProvisioning.
  Fix NPE
  Prevent non-admin users from deleting system apps.
  Fix security hole in GateKeeperResponse
  DO NOT MERGE Add an OEM configurable limit for zen rules
  Update GeofenceHardwareRequestParcelable to match parcel/unparcel format.

Change-Id: I253da8c9f716439e73108e0568f9934a1984c134
parents a7e586e2 82f6df1c
Loading
Loading
Loading
Loading
+22 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ package android.app.admin;
import static com.android.internal.util.function.pooled.PooledLambda.obtainMessage;
import android.Manifest.permission;
import android.accounts.Account;
import android.annotation.CallbackExecutor;
import android.annotation.ColorInt;
import android.annotation.IntDef;
@@ -152,6 +153,27 @@ public class DevicePolicyManager {
        this(context, service, false);
    }
    /**
     * Called when a managed profile has been provisioned.
     *
     * @throws SecurityException if the caller does not hold
     * {@link android.Manifest.permission#MANAGE_PROFILE_AND_DEVICE_OWNERS}.
     * @hide
     */
    @RequiresPermission(android.Manifest.permission.MANAGE_PROFILE_AND_DEVICE_OWNERS)
    public void finalizeWorkProfileProvisioning(
            @NonNull UserHandle managedProfileUser, @Nullable Account migratedAccount) {
        Objects.requireNonNull(managedProfileUser, "managedProfileUser can't be null");
        if (mService == null) {
            throw new IllegalStateException("Could not find DevicePolicyManagerService");
        }
        try {
            mService.finalizeWorkProfileProvisioning(managedProfileUser, migratedAccount);
        } catch (RemoteException e) {
            throw e.rethrowFromSystemServer();
        }
    }
    /** @hide */
    @VisibleForTesting
    protected DevicePolicyManager(Context context, IDevicePolicyManager service,
+3 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@

package android.app.admin;

import android.accounts.Account;
import android.app.admin.NetworkEvent;
import android.app.IApplicationThread;
import android.app.IServiceConnection;
@@ -91,6 +92,8 @@ interface IDevicePolicyManager {
    int getCurrentFailedPasswordAttempts(int userHandle, boolean parent);
    int getProfileWithMinimumFailedPasswordsForWipe(int userHandle, boolean parent);

    void finalizeWorkProfileProvisioning(in UserHandle managedProfileUser, in Account migratedAccount);

    void setMaximumFailedPasswordsForWipe(in ComponentName admin, int num, boolean parent);
    int getMaximumFailedPasswordsForWipe(in ComponentName admin, int userHandle, boolean parent);

+3 −6
Original line number Diff line number Diff line
@@ -16,9 +16,9 @@

package android.hardware.location;

import android.os.BadParcelableException;
import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;

/**
 * Geofence Hardware Request used for internal location services communication.
@@ -140,10 +140,7 @@ public final class GeofenceHardwareRequestParcelable implements Parcelable {
        public GeofenceHardwareRequestParcelable createFromParcel(Parcel parcel) {
            int geofenceType = parcel.readInt();
            if (geofenceType != GeofenceHardwareRequest.GEOFENCE_TYPE_CIRCLE) {
                Log.e(
                        "GeofenceHardwareRequest",
                        String.format("Invalid Geofence type: %d", geofenceType));
                return null;
                throw new BadParcelableException("Invalid Geofence type: " + geofenceType);
            }

            GeofenceHardwareRequest request = GeofenceHardwareRequest.createCircularGeofence(
+1 −1
Original line number Diff line number Diff line
@@ -105,7 +105,7 @@ public final class GateKeeperResponse implements Parcelable {
            dest.writeInt(mTimeout);
        } else if (mResponseCode == RESPONSE_OK) {
            dest.writeInt(mShouldReEnroll ? 1 : 0);
            if (mPayload != null) {
            if (mPayload != null && mPayload.length > 0) {
                dest.writeInt(mPayload.length);
                dest.writeByteArray(mPayload);
            } else {
+1 −0
Original line number Diff line number Diff line
@@ -96,6 +96,7 @@
    <protected-broadcast android:name="android.intent.action.OVERLAY_PRIORITY_CHANGED" />
    <protected-broadcast android:name="android.intent.action.MY_PACKAGE_SUSPENDED" />
    <protected-broadcast android:name="android.intent.action.MY_PACKAGE_UNSUSPENDED" />
    <protected-broadcast android:name="android.app.action.MANAGED_PROFILE_PROVISIONED" />

    <protected-broadcast android:name="android.os.action.POWER_SAVE_MODE_CHANGED" />
    <protected-broadcast android:name="android.os.action.POWER_SAVE_MODE_CHANGING" />
Loading