am 8b626548: Merge "Pass privapp specifier for selinux labeling"
* commit '8b62654855b105e5ff7628107691309a63effe0c': Pass privapp specifier for selinux labeling
This commit is contained in:
committed by
Android Git Automerger
commit
a2e511d6ca
@@ -100,6 +100,9 @@ public final class SELinuxMMAC {
|
|||||||
private static final String SEAPP_HASH_FILE =
|
private static final String SEAPP_HASH_FILE =
|
||||||
Environment.getDataDirectory().toString() + "/system/seapp_hash";
|
Environment.getDataDirectory().toString() + "/system/seapp_hash";
|
||||||
|
|
||||||
|
// Append privapp to existing seinfo label
|
||||||
|
private static final String PRIVILEGED_APP_STR = ":privapp";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load the mac_permissions.xml file containing all seinfo assignments used to
|
* Load the mac_permissions.xml file containing all seinfo assignments used to
|
||||||
* label apps. The loaded mac_permissions.xml file is determined by the
|
* label apps. The loaded mac_permissions.xml file is determined by the
|
||||||
@@ -313,6 +316,9 @@ public final class SELinuxMMAC {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (pkg.applicationInfo.isPrivilegedApp())
|
||||||
|
pkg.applicationInfo.seinfo += PRIVILEGED_APP_STR;
|
||||||
|
|
||||||
if (DEBUG_POLICY_INSTALL) {
|
if (DEBUG_POLICY_INSTALL) {
|
||||||
Slog.i(TAG, "package (" + pkg.packageName + ") labeled with " +
|
Slog.i(TAG, "package (" + pkg.packageName + ") labeled with " +
|
||||||
"seinfo=" + pkg.applicationInfo.seinfo);
|
"seinfo=" + pkg.applicationInfo.seinfo);
|
||||||
|
|||||||
Reference in New Issue
Block a user