Merge "Move ephemeral apps into the ephemeral SELinux domain"
This commit is contained in:
committed by
Android (Google) Code Review
commit
cbc59b8aa6
@@ -488,14 +488,6 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable {
|
||||
*/
|
||||
public static final int PRIVATE_FLAG_DIRECT_BOOT_AWARE = 1 << 6;
|
||||
|
||||
/**
|
||||
* Value for {@link #privateFlags}: set to {@code true} if the application
|
||||
* is AutoPlay.
|
||||
*
|
||||
* {@hide}
|
||||
*/
|
||||
public static final int PRIVATE_FLAG_AUTOPLAY = 1 << 7;
|
||||
|
||||
/**
|
||||
* When set, at least one component inside this application is direct boot
|
||||
* aware.
|
||||
@@ -1194,13 +1186,6 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable {
|
||||
return (privateFlags & ApplicationInfo.PRIVATE_FLAG_PARTIALLY_DIRECT_BOOT_AWARE) != 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
public boolean isAutoPlayApp() {
|
||||
return (privateFlags & ApplicationInfo.PRIVATE_FLAG_AUTOPLAY) != 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
|
||||
@@ -65,8 +65,8 @@ public final class SELinuxMMAC {
|
||||
// Append privapp to existing seinfo label
|
||||
private static final String PRIVILEGED_APP_STR = ":privapp";
|
||||
|
||||
// Append autoplay to existing seinfo label
|
||||
private static final String AUTOPLAY_APP_STR = ":autoplayapp";
|
||||
// Append ephemeral to existing seinfo label
|
||||
private static final String EPHEMERAL_APP_STR = ":ephemeralapp";
|
||||
|
||||
/**
|
||||
* Load the mac_permissions.xml file containing all seinfo assignments used to
|
||||
@@ -281,8 +281,8 @@ public final class SELinuxMMAC {
|
||||
}
|
||||
}
|
||||
|
||||
if (pkg.applicationInfo.isAutoPlayApp())
|
||||
pkg.applicationInfo.seinfo += AUTOPLAY_APP_STR;
|
||||
if (pkg.applicationInfo.isEphemeralApp())
|
||||
pkg.applicationInfo.seinfo += EPHEMERAL_APP_STR;
|
||||
|
||||
if (pkg.applicationInfo.isPrivilegedApp())
|
||||
pkg.applicationInfo.seinfo += PRIVILEGED_APP_STR;
|
||||
|
||||
@@ -4263,7 +4263,6 @@ final class Settings {
|
||||
ApplicationInfo.PRIVATE_FLAG_HAS_DOMAIN_URLS, "HAS_DOMAIN_URLS",
|
||||
ApplicationInfo.PRIVATE_FLAG_DEFAULT_TO_DEVICE_PROTECTED_STORAGE, "DEFAULT_TO_DEVICE_PROTECTED_STORAGE",
|
||||
ApplicationInfo.PRIVATE_FLAG_DIRECT_BOOT_AWARE, "DIRECT_BOOT_AWARE",
|
||||
ApplicationInfo.PRIVATE_FLAG_AUTOPLAY, "AUTOPLAY",
|
||||
ApplicationInfo.PRIVATE_FLAG_PARTIALLY_DIRECT_BOOT_AWARE, "PARTIALLY_DIRECT_BOOT_AWARE",
|
||||
ApplicationInfo.PRIVATE_FLAG_EPHEMERAL, "EPHEMERAL",
|
||||
ApplicationInfo.PRIVATE_FLAG_REQUIRED_FOR_SYSTEM_USER, "REQUIRED_FOR_SYSTEM_USER",
|
||||
|
||||
Reference in New Issue
Block a user