Merge "Allow unexported receiver registration for sandbox" into tm-dev am: b24001b123
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17377951 Change-Id: I933fc25fbd66380d3da083f6553415374bf81714 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -12945,7 +12945,12 @@ public class ActivityManagerService extends IActivityManager.Stub
|
|||||||
public Intent registerReceiverWithFeature(IApplicationThread caller, String callerPackage,
|
public Intent registerReceiverWithFeature(IApplicationThread caller, String callerPackage,
|
||||||
String callerFeatureId, String receiverId, IIntentReceiver receiver,
|
String callerFeatureId, String receiverId, IIntentReceiver receiver,
|
||||||
IntentFilter filter, String permission, int userId, int flags) {
|
IntentFilter filter, String permission, int userId, int flags) {
|
||||||
|
// Allow Sandbox process to register only unexported receivers.
|
||||||
|
if ((flags & Context.RECEIVER_NOT_EXPORTED) != 0) {
|
||||||
|
enforceNotIsolatedCaller("registerReceiver");
|
||||||
|
} else {
|
||||||
enforceNotIsolatedOrSdkSandboxCaller("registerReceiver");
|
enforceNotIsolatedOrSdkSandboxCaller("registerReceiver");
|
||||||
|
}
|
||||||
ArrayList<Intent> stickyIntents = null;
|
ArrayList<Intent> stickyIntents = null;
|
||||||
ProcessRecord callerApp = null;
|
ProcessRecord callerApp = null;
|
||||||
final boolean visibleToInstantApps
|
final boolean visibleToInstantApps
|
||||||
|
|||||||
Reference in New Issue
Block a user