From 35b79a7d44b816c6bdbde9de19e8a86f6f782b52 Mon Sep 17 00:00:00 2001 From: Chad Brubaker Date: Wed, 25 Jan 2017 14:09:22 -0800 Subject: [PATCH] Allow ephemeral apps to reach any CATEGORY_BROWSABLE Apps receiving browsable intents should already be prompting the user before taking any action/making any changes, which is what we want to ensure for ephemeral apps. This way we don't have to manually mark all such activities visibleToInstantApps. Test: cts-tradefed run commandAndExit cts-dev -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.EphemeralTest Change-Id: Id64706f993a412f163e533fa85b83f5f466731f7 --- core/java/android/content/pm/PackageParser.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/java/android/content/pm/PackageParser.java b/core/java/android/content/pm/PackageParser.java index 8223726322a5c..43053446b9350 100644 --- a/core/java/android/content/pm/PackageParser.java +++ b/core/java/android/content/pm/PackageParser.java @@ -5028,9 +5028,7 @@ public class PackageParser { } private boolean isWebBrowsableIntent(IntentInfo intent) { - return intent.hasAction(Intent.ACTION_VIEW) - && intent.hasCategory(Intent.CATEGORY_BROWSABLE) - && (intent.hasDataScheme("http") || intent.hasDataScheme("https")); + return intent.hasCategory(Intent.CATEGORY_BROWSABLE); } private boolean parseAllMetaData(Resources res, XmlResourceParser parser, String tag,