Commit Graph

6545 Commits

Author SHA1 Message Date
Michal Karpinski
808d8a0163 Merge "Allow restoring of apps that rotated key" into pi-dev am: d766e212c9
am: f89a90bcca

Change-Id: I0895c47a93d7bd3b90a89bd0b0dce2cc24fcb963
2018-03-15 10:41:22 +00:00
Michal Karpinski
d766e212c9 Merge "Allow restoring of apps that rotated key" into pi-dev 2018-03-15 10:13:34 +00:00
Chad Brubaker
c1544af88a Merge "Merge "Fix cleartext default for the manifest value" into pi-dev am: 75a3173245" into pi-dev-plus-aosp
am: a957321189

Change-Id: Iae321380f76f4176370d3daec4098d85fc29b028
2018-03-15 04:47:06 +00:00
TreeHugger Robot
75a3173245 Merge "Fix cleartext default for the manifest value" into pi-dev 2018-03-15 02:50:20 +00:00
Yohei Yukawa
1772885497 Merge "Also apply prefix when dumping isAllowedToUseHiddenApi" into pi-dev am: 265b11ffb2
am: 231262c42b

Change-Id: Ife192204965b1953b603262e140027520f460131
2018-03-15 01:06:23 +00:00
TreeHugger Robot
265b11ffb2 Merge "Also apply prefix when dumping isAllowedToUseHiddenApi" into pi-dev 2018-03-15 00:37:37 +00:00
Yohei Yukawa
f3ca7a73dc Also apply prefix when dumping isAllowedToUseHiddenApi
This is a follow up CL to a CL [1] that added one more state dump from
ApplicationInfo regarding whether the app is exampted from the API
restriction but forgot to take care of prefix handling.

 [1]: I01e837253d00c6ffa841a9e5c226204a3e11b827
      974290b032

Bug: 64382372
Test: Ran the following command to see "isAllowedToUseHiddenApi"
      is aligned with other outputs from ApplicationInfo.
         adb shell ime list -a
Change-Id: I9c77d9b557245b7f3b51631140bd564feef601ce
2018-03-14 13:43:47 -07:00
Todd Kennedy
662504f941 Enable local search for instant apps
When getting the set of searchable activities, fetch instant
applications. But, this means that the set needs a final
filter to prevent leaking application existence.

Change-Id: I6b9daf031ce54061c4500d9edae1d738848158c4
Fixes: 68211791
Test: atest -it CtsAppSecurityHostTestCases:EphemeralTest#testGetSearchableInfo
(cherry picked from commit 8b9d664cae)
2018-03-14 20:31:11 +00:00
TreeHugger Robot
9794ed6844 Merge "Enable local search for instant apps" 2018-03-14 20:25:51 +00:00
Felipe Leme
0dc5ea2bf9 Merge "Removed redundant method ContentResolver.releasePersistableUriPermission()" into pi-dev am: 5741823729
am: 89ad93f457

Change-Id: Icc739e5befce0d3c51f397532f49cee0af5d3c7e
2018-03-14 19:14:12 +00:00
TreeHugger Robot
5741823729 Merge "Removed redundant method ContentResolver.releasePersistableUriPermission()" into pi-dev 2018-03-14 18:42:38 +00:00
Chad Brubaker
0d285d5117 Fix cleartext default for the manifest value
If no network security config is set the default value of
cleartextTrafficPermitted comes from the legacy
android:cleartextTrafficPermitted, default this to false for apps
targeting P to track the network security config behavior as was
intended.

Bug: 74587672
Test: atest CtsNetSecPolicyUsesCleartextTrafficUnspecifiedTestCases
Change-Id: I6367723befa1b947063554c9c061bdfc5be3d116
2018-03-14 09:45:52 -07:00
Michal Karpinski
528c3e572a Allow restoring of apps that rotated key
Restoring of apps that rotated key wouldn't be possible due to
explicit signature matching.
Amend signature matching strategies to take into account
apps that have rotated key.

Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/backup/utils/AppBackupUtilsTest.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/backup/BackupUtilsTest.java
Test: m -j RunFrameworksServicesRoboTests
Test: runtest -p com.android.server.backup frameworks-services
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest1.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest2.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest3.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest4.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest5.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest6.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest7.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest8.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest9.java
Test: atest frameworks/base/services/tests/servicestests/src/
      com/android/server/pm/ShortcutManagerTest10.java
Test: atest CtsShortcutManagerTestCases
Bug: 64686581
Bug: 34345052
Bug: 74208476
Bug: 74159113

Change-Id: Ica23bbfec89648d9348c65db4597188e8c18e1d8
2018-03-14 16:11:18 +00:00
Todd Kennedy
8b9d664cae Enable local search for instant apps
When getting the set of searchable activities, fetch instant
applications. But, this means that the set needs a final
filter to prevent leaking application existence.

Change-Id: I6b9daf031ce54061c4500d9edae1d738848158c4
Fixes: 68211791
Test: atest -it CtsAppSecurityHostTestCases:EphemeralTest#testGetSearchableInfo
2018-03-14 08:25:20 -07:00
Fyodor Kupolov
0bb2a9da05 Merge "Added ACTION_BATTERY_LEVEL_CHANGED" into pi-dev am: 04782e277c
am: 8ac8356b51

Change-Id: Ie4ecb38345003c3d450361044a6a31120d600352
2018-03-10 07:09:14 +00:00
Todd Kennedy
5fdbabb5dc Fix doc bugs
* Add more words around the install reason in the SessionParams. Document
  the fact that the value is somewhat arbitrary, but, clients should try
  to use one of the defined values

* Clarify that the "name" parameter for resolveContentProvider() is really
  the URI authority. Add a small code snippet.

Change-Id: I60f152439f04ce85a9f0ed67504424190b9ef3bd
Fixes: 66448772
Fixes: 66471537
Test: None. This only changed javadoc
2018-03-08 10:55:19 -08:00
Fyodor Kupolov
70e7543066 Added ACTION_BATTERY_LEVEL_CHANGED
Sent when the current battery level changes.

It has EXTRA_EVENTS that carries a list of Bundle instances representing
individual battery level changes with associated extras from
ACTION_BATTERY_CHANGED

Each event has EXTRA_EVENT_TIMESTAMP representing time when it occured.

Test: manual
Bug: 74020080
Change-Id: I993005950299c5298c9111ca51cc7717e1f029de
2018-03-08 10:09:01 -08:00
Jeff Vander Stoep
cab3639dcb Revert "Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion""
Commit 042f4bb6 'pm: Modify getPackage() to only return non-null
packages' prevents the NullPointerException. b/
This reverts commit 00b4fa8b13.

Bug: 74214574
Bug: 72290969
Test: Same tests run on original commit.
Test: successfully flash and boot from bild 4504078 to ToT master.
Change-Id: Ia1e900ebe0eb8f9d10fd0eddbf658f52e1ea79b4
(cherry picked from commit 32ef1c2eb0)
2018-03-07 18:49:12 +00:00
TreeHugger Robot
761862a256 Merge "Revert "Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion""" 2018-03-07 18:43:24 +00:00
TreeHugger Robot
99d753b4a1 Merge "Fix comment typos in ApplicationInfo." 2018-03-07 15:07:55 +00:00
Jeff Vander Stoep
32ef1c2eb0 Revert "Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion""
Commit 042f4bb6 'pm: Modify getPackage() to only return non-null
packages' prevents the NullPointerException. b/
This reverts commit 00b4fa8b13.

Bug: 74214574
Bug: 72290969
Test: Same tests run on original commit.
Test: successfully flash and boot from bild 4504078 to ToT master.
Change-Id: Ia1e900ebe0eb8f9d10fd0eddbf658f52e1ea79b4
2018-03-06 16:51:26 -08:00
Jeffrey Vander Stoep
85d1b5c414 Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion"
This reverts commit 8196fd9380.

Reason for revert: b/74214574

Bug: 74214574
Change-Id: I9602872238ccc8a49d8b200e5389995d597f1c3a
(cherry picked from commit 00b4fa8b13)
2018-03-06 15:12:15 +00:00
TreeHugger Robot
e4936647e9 Merge "Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion"" 2018-03-06 14:43:35 +00:00
Mathew Inwood
c14f832a66 Fix comment typos in ApplicationInfo.
@linl -> @link

Test: N/A
Change-Id: I6f295101e4d3e8c4b7596e74197e4ea39bbf6e2b
2018-03-06 14:37:42 +00:00
TreeHugger Robot
3fbc54e609 Merge "Don't whitelist all system image apps." into pi-dev 2018-03-06 11:50:23 +00:00
Mathew Inwood
6827f4a2c8 Don't whitelist all system image apps.
Also include in system dump which packages are exempt from the api
restrictions.

This is a cherry-pick of 974290b032
from master.

Test: Verified that the device boots.
Bug: 64382372
Change-Id: Iaeca91478f53c8b4e9608246aab42bdb90f899bb
2018-03-06 09:54:55 +00:00
Jeffrey Vander Stoep
00b4fa8b13 Revert "pm: SharedUserId: Assign seinfo using actual targetSdkVersion"
This reverts commit 8196fd9380.

Reason for revert: b/74214574

Bug: 74214574
Change-Id: I9602872238ccc8a49d8b200e5389995d597f1c3a
2018-03-06 08:22:20 +00:00
Fyodor Kupolov
8db0bf356a Merge "Revert "Allow restoring of apps that rotated key"" into pi-dev am: d97a0f1ac5
am: d4315862cc

Change-Id: Ia73f006301d8225f7906612faa381f4307a23b51
2018-03-06 07:18:09 +00:00
Felipe Leme
bb01e5e538 Removed redundant method ContentResolver.releasePersistableUriPermission()
Bug: 72055774

Test: manual verification
Test: atest CtsAppSecurityHostTestCases:ScopedDirectoryAccessTest#testResetGranted

Change-Id: Iab6dde04b0dc43f97e1a66f665cf5f6f3e078381
2018-03-05 14:09:46 -08:00
Amith Yamasani
14c716c911 Revert "Allow restoring of apps that rotated key"
This reverts commit 313d225cd1.

Reason for revert: b/74159113

Change-Id: I483ecdd80d26fca8451cd270b4fcbe34379839cb
2018-03-05 20:40:23 +00:00
TreeHugger Robot
a597260ba2 Merge "Don't whitelist all system image apps." 2018-03-05 13:34:24 +00:00
Adam Lesinski
40a32d9ff0 Merge "Refactor AssetManager" 2018-03-02 22:05:45 +00:00
TreeHugger Robot
15881d7c0c Merge "pm: SharedUserId: Assign seinfo using actual targetSdkVersion" 2018-03-02 21:56:30 +00:00
TreeHugger Robot
fddc22678c Merge "Copy PermissionChecker from support lib and use in RcognitionService" 2018-03-02 20:01:33 +00:00
TreeHugger Robot
6f5ed04ab7 Merge "Addresses API feedback for Intent Discovery change" 2018-03-02 15:52:32 +00:00
Mathew Inwood
974290b032 Don't whitelist all system image apps.
Also include in system dump which packages are exempt from the api
restrictions.

Test: Verified that the device boots.
Bug: 64382372
Change-Id: I01e837253d00c6ffa841a9e5c226204a3e11b827
2018-03-02 12:41:20 +00:00
Jeff Sharkey
341c2366cc Merge "Force loading of safe labels in system_server." 2018-03-01 18:04:16 +00:00
Patrick Baumann
3abf547d1f Addresses API feedback for Intent Discovery change
* Clarifies purpose and effects of resolver methods
* Adds javadocs to non-obvious constructors and constants

Test: none - no functional changes
Bug: 73950163
Change-Id: Id668b890a8c97da74502698f71b16cc213eda6c6
2018-03-01 10:03:05 -08:00
TreeHugger Robot
15c3e602e9 Merge "Removed AMS.updatePersistableUriPermission()" 2018-03-01 17:30:33 +00:00
Adam Lesinski
bebfcc46a2 Refactor AssetManager
Bug: 64071469
Test: atest CtsContentTestCases
Change-Id: Ia6856157e8813856268fba003e1e591d690cb26e
2018-02-28 19:06:48 -08:00
TreeHugger Robot
50db5a45ac Merge "Make activity-alias inherit "enableVrMode" attribute from target activity." 2018-03-01 02:59:49 +00:00
Jeff Vander Stoep
8196fd9380 pm: SharedUserId: Assign seinfo using actual targetSdkVersion
Assign the targetSdkVersion component of SeInfo using the lowest
targetSdkVersion of all apps within a SharedUserId.

Bug: 72290969
Test: cts-tradefed run cts -m CtsAppSecurityHostTestCases
Test: cts-tradefed run cts -m CtsSelinuxTargetSdk{current,25,27}TestCases
Test: install sharedUserId app with targetSdkVersion=28, then install
    app with targetSdkVersion=26. Verify that they share the same domain
    and data is correctly labeled.
Change-Id: I9476d10bf3c6a769d63a45a4314aaa91203880b8
2018-02-28 16:59:34 -08:00
Joe Maples
6997ad6926 Merge "pm: Fix typo in error" am: a12e18bcd1 am: a79fef132b
am: 1ec4c3b3b1

Change-Id: I9d1b48c0852bc75108ab72cd4c58c08a43b62a8b
2018-03-01 00:09:25 +00:00
Joe Maples
1ec4c3b3b1 Merge "pm: Fix typo in error" am: a12e18bcd1
am: a79fef132b

Change-Id: I45fa701a8f9e727e1a072f4f6dd773bba0de01aa
2018-03-01 00:00:13 +00:00
TreeHugger Robot
19130fea91 Merge "More work on issue #73301635: Ability to extract device configuration" 2018-02-28 23:19:13 +00:00
Felipe Leme
988234a343 Removed AMS.updatePersistableUriPermission()
Bug: 72055774

Test: manual verification
Test: atest CtsAppSecurityHostTestCases:ScopedDirectoryAccessTest#testResetDoNotAskAgain,testResetGranted
Test: atest CtsAppSecurityHostTestCases:ScopedDirectoryAccessTest

Change-Id: I90cd9a79a1caa19989e00dbc1a656469bc3221f9
2018-02-28 15:15:37 -08:00
Jeff Sharkey
b0613dceb0 Force loading of safe labels in system_server.
It's too easy for code to accidentally use loadLabel() when building
strings for security sensitive contexts, so add ability for a process
to always force loading of safe strings.

Test: builds, boots
Bug: 73657770
Change-Id: I1c7645bd7bebed0cfb6bc3e5bfd36c8cb11d4838
2018-02-28 23:06:04 +00:00
TreeHugger Robot
501427818a Merge "Add component ordering" 2018-02-28 21:54:03 +00:00
Dianne Hackborn
337e01ac10 More work on issue #73301635: Ability to extract device configuration
Now include Gl extensions (thanks to whoever wrote the code
I copied!).

Tweak the protos a bit to include missing info and correct
some things.

Add some new test APIs that are needed for CTS.

Bug: 73301635
Test: atest CtsActivityManagerDeviceTestCases:ActivityManagerGetConfigTests
Change-Id: Ie3f8173d217468246e8b6c7f45b7cbfcb352d60f
2018-02-28 11:29:20 -08:00
Joe Maples
39bb9e8905 pm: Fix typo in error
instnat -> instant

Change-Id: Ie2f06840575fc266e3510252635ad17be65945b8
Signed-off-by: Joe Maples <joe@frap129.org>
2018-02-28 18:42:08 +00:00