Commit Graph

483122 Commits

Author SHA1 Message Date
Oli Lan
fbfa268d47 Prevent non-admin users from deleting system apps.
This addresses a security issue where the guest user can remove updates
for system apps.

With this CL, attempts to uninstall/downgrade system apps will fail if
attempted by a non-admin user, unless the DELETE_SYSTEM_APP flag is
specified.

This is a fixed version of ag/17408864, to address b/236578018.

Bug: 170646036
Test: manual, try uninstalling system app update as guest
Merged-In: I4e959e296cca9bbdfc8fccc5e5e0e654ca524165
Change-Id: I6ecfef50294c9000a6ce539bdec6f372c872a40b
2022-08-09 17:43:44 +00:00
Oli Lan
d69df94c24 [automerger skipped] Merge "Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps."" into qt-dev am: 82a9fa1667 am: fb6f84fe35 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19337226

Change-Id: I6b52e16af09235bf13cc1c2b4c12299bc7c2fbba
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-08 10:54:17 +00:00
Oli Lan
2f4d46fca2 [automerger skipped] Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps." am: 49d8f9325a am: cf5587d2ca -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19337226

Change-Id: I34823ac46a356f70554c8c1c9bfe4e8a54fc7cdc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-08 10:53:57 +00:00
Oli Lan
fb6f84fe35 Merge "Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps."" into qt-dev am: 82a9fa1667
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19337226

Change-Id: Ie9e4bde2bc2ad7fb63a770e9f56ea731786a09da
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-08 10:38:31 +00:00
Oli Lan
cf5587d2ca Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps." am: 49d8f9325a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19337226

Change-Id: I25f5944fcf0d975ab8f202e5701ea28b681544f2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-08 10:38:18 +00:00
Oli Lan
82a9fa1667 Merge "Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps."" into qt-dev 2022-08-08 10:08:09 +00:00
Oli Lan
fefefdc7ff Merge "Revert "Prevent non-admin users from deleting system apps."" into rvc-dev 2022-08-08 10:07:34 +00:00
Aseem Kumar
ea3ccf17fe Merge "DO NOT MERGE Move accountname and typeName length check from Account.java to AccountManagerService." into rvc-dev 2022-08-05 21:38:57 +00:00
Aseem Kumar
a7fd96bf38 [automerger skipped] DO NOT MERGE am: 3f218c9a5e am: e0243c7661 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17595878

Change-Id: I662d6e6e5476b298d24de3903bc7cfa2f339afb9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-05 19:15:08 +00:00
Aseem Kumar
e0243c7661 DO NOT MERGE am: 3f218c9a5e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17595878

Change-Id: Ide4ce7536d9637969b483d05f729e6d8c800b49c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-05 18:33:55 +00:00
Aseem Kumar
3f218c9a5e DO NOT MERGE
Move accountname and typeName length check from Account.java to AccountManagerService.

Bug: 169762606
Test: atest AccountManagerServiceTest
Change-Id: I80fabf3a64c55837db98ff316e7e5420129c001b
2022-08-04 22:21:52 +00:00
Aseem Kumar
aa58f99079 DO NOT MERGE
Move accountname and typeName length check from Account.java to AccountManagerService.

Bug: 169762606
Test: atest AccountManagerServiceTest
Change-Id: I80fabf3a64c55837db98ff316e7e5420129c001b
(cherry picked from commit 0adcadb0b2)
Merged-In: I80fabf3a64c55837db98ff316e7e5420129c001b
2022-08-04 06:54:29 +00:00
Jeff DeCew
2bd5ab6f26 [automerger skipped] RESTRICT AUTOMERGE: Fix build breakage from merge conflict. am: 518980587b -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19498370

Change-Id: Idf13340b59f5d67c7c4582d339d92f94905fae08
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 20:21:28 +00:00
Jeff DeCew
518980587b RESTRICT AUTOMERGE: Fix build breakage from merge conflict.
Merging 8ce3c53fcf into qt-qpr1-dev resulted in a merge conflict due to a method being moved between qt-qpr1-dev and rvc-dev, such that the patch backported from rvc-dev didn't match at all.  Removing the old method makes this branch match qt-dev and rvc-dev.

Test: will use abtd to validate the build and the resulting logic.

Original changes: Id82d20c9f1f2001400871b5381f52b40fbdf81c5

Original
Bug: 231322873

Breakage
Bug: 241087006

Change-Id: Ic4f8d701d97aa9b6c72875df8c7eab5fd51934e0
2022-08-02 14:05:08 +00:00
Jeff DeCew
d011967068 [automerger skipped] Merge "Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior." into qt-dev am: b38c650ea9 am: 7330570922 -s ours
am skip reason: Merged-In Id82d20c9f1f2001400871b5381f52b40fbdf81c5 with SHA-1 09761a98b5 is already in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19346142

Change-Id: Id519e6c7a071bc726f645eda89ddb36d547786fd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 12:37:53 +00:00
Jeff DeCew
7330570922 Merge "Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior." into qt-dev am: b38c650ea9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19346142

Change-Id: If6faade37cf6df1dcd7a1574b341b4fc9f3dabbd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 12:22:05 +00:00
Jeff DeCew
b38c650ea9 Merge "Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior." into qt-dev 2022-08-02 11:56:41 +00:00
Jeff DeCew
e35bab3aa0 Merge "Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior." into rvc-dev 2022-08-01 19:18:45 +00:00
Suprabh Shukla
da44101e4f Merge "Stop crashing the system on hitting the alarm limit" into rvc-dev 2022-07-22 04:35:18 +00:00
Oli Lan
d9089fbe06 Revert "Prevent non-admin users from deleting system apps."
This reverts commit 6c870e1579.

Reason for revert: Regression, DELETE_SYSTEM_APP flag no longer works

Change-Id: Id3eb9e08a5404e88c39235d0d47337ed41bc6139
Merged-In: I4e959e296cca9bbdfc8fccc5e5e0e654ca524165
2022-07-20 10:12:40 +00:00
Suprabh Shukla
909251a2ca Stop crashing the system on hitting the alarm limit
Exempting the system as a runtime restart is not clearly
better than extreme memory and computation pressure that can result from
the originating spam.
Callers in the system should guard against any spammy requests that lead
them to create a lot of alarms.

Test: Builds, boots and existing tests should pass.

atest CtsAlarmManagerTestCases:UidCapTests
atest FrameworksMockingServicesTests:AlarmManagerServiceTest

Bug: 234441463
Change-Id: Id5e94d44ac9ab24870a8213ec7583da0f592a5ff
(cherry picked from commit 3b9f3f4a0f)
Merged-In: Id5e94d44ac9ab24870a8213ec7583da0f592a5ff
(cherry picked from commit c010da3a46)
2022-07-20 07:02:12 +00:00
Suprabh Shukla
ff26f6a3b7 [automerger skipped] Stop crashing the system on hitting the alarm limit am: c010da3a46 am: ee9331c0d3 -s ours
am skip reason: skipped by user suprabh

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19105069

Change-Id: I06963a3201ef81c1fe537bab7a1d51f1e305a924
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-20 07:02:11 +00:00
Suprabh Shukla
ee9331c0d3 Stop crashing the system on hitting the alarm limit am: c010da3a46
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19105069

Change-Id: I0fe52c40c5e9d38ea5c4d31dd901c1c03d5f8ccb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-20 04:39:11 +00:00
Suprabh Shukla
c010da3a46 Stop crashing the system on hitting the alarm limit
Exempting the system as a runtime restart is not clearly
better than extreme memory and computation pressure that can result from
the originating spam.
Callers in the system should guard against any spammy requests that lead
them to create a lot of alarms.

Test: Builds, boots and existing tests should pass.

atest CtsAlarmManagerTestCases:UidCapTests
atest FrameworksMockingServicesTests:AlarmManagerServiceTest

Bug: 234441463
Change-Id: Id5e94d44ac9ab24870a8213ec7583da0f592a5ff
(cherry picked from commit 3b9f3f4a0f)
Merged-In: Id5e94d44ac9ab24870a8213ec7583da0f592a5ff
2022-07-20 01:48:40 +00:00
Jeff DeCew
8ce3c53fcf Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior.
Bug: 231322873
Test: atest NotificationInterruptStateProviderImplTest
Merged-In: Id82d20c9f1f2001400871b5381f52b40fbdf81c5
Change-Id: Id82d20c9f1f2001400871b5381f52b40fbdf81c5
2022-07-20 01:13:11 +00:00
Jeff DeCew
09761a98b5 Block FullScreenIntent while device is in use if notification has a silencing GroupAlertBehavior.
Bug: 231322873
Test: atest NotificationInterruptStateProviderImplTest
Merged-In: Id82d20c9f1f2001400871b5381f52b40fbdf81c5
Change-Id: Id82d20c9f1f2001400871b5381f52b40fbdf81c5
2022-07-20 00:48:11 +00:00
Julia Reynolds
a6d920e3d6 [automerger skipped] DO NOT MERGE Limit the number of concurrently snoozed notifications am: c38cc3e355 am: c1d1396751 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19205944

Change-Id: Ia0cba09ba7d819239928de3a1ff04d14f2a01b7c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-19 20:19:17 +00:00
Julia Reynolds
c1d1396751 DO NOT MERGE Limit the number of concurrently snoozed notifications am: c38cc3e355
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19205944

Change-Id: I7170c031c2aa4ca409eb1965c6ed20085fac7801
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-19 20:02:16 +00:00
Oli Lan
49d8f9325a Revert "RESTRICT AUTOMERGE Prevent non-admin users from deleting system apps."
This reverts commit a7621e0ce0.

Reason for revert: Regression, DELETE_SYSTEM_APP flag no longer works

Change-Id: I7386d1ba3d61b95836b85c52214c83b216c478e8
2022-07-19 10:45:22 +00:00
Julia Reynolds
c38cc3e355 DO NOT MERGE Limit the number of concurrently snoozed notifications
Test: atest FrameworksUiServicesTests
Bug: 234441463
Change-Id: I005b43979d1c708fd505c8b33ae0c8cb03ddbb35
Merged-In: I005b43979d1c708fd505c8b33ae0c8cb03ddbb35
(cherry picked from commit 7c38394ae9)
2022-07-08 15:39:10 +00:00
Julia Reynolds
455a525421 Limit the number of concurrently snoozed notifications
Test: atest FrameworksUiServicesTests
Bug: 234441463
Change-Id: I005b43979d1c708fd505c8b33ae0c8cb03ddbb35
Merged-In: I005b43979d1c708fd505c8b33ae0c8cb03ddbb35
(cherry picked from commit 7c38394ae9)
2022-07-07 14:16:28 +00:00
Manjeet Rulhania
d307aa8bed [automerger skipped] Merge "Remove package name from SafetyNet logs" into qt-dev am: 2c12354e77 am: ca9d475ba4 -s ours
am skip reason: Merged-In I993832e148636f1795ffe393c6dc74a08b9442f8 with SHA-1 bbe2a11827 is already in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19138582

Change-Id: I1290e5a56b9b6585e296cae9e922edc109f9862b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-06 23:23:15 +00:00
Manjeet Rulhania
ca9d475ba4 Merge "Remove package name from SafetyNet logs" into qt-dev am: 2c12354e77
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19138582

Change-Id: I7a24c7dfcb26195913cb36f1f8bc118844953891
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-06 22:58:18 +00:00
Manjeet Rulhania
2c12354e77 Merge "Remove package name from SafetyNet logs" into qt-dev 2022-07-06 22:32:27 +00:00
Manjeet Rulhania
fa04b36240 Merge "Remove package name from SafetyNet logs" into rvc-dev 2022-07-06 21:43:00 +00:00
TreeHugger Robot
02bf64594b Merge "IMMS: Make IMMS PendingIntents immutable" into qt-dev am: 5ccf55eb8a am: 6c68f5019f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19119301

Change-Id: I0d1cc16c84d5909e32efacfff3605cafbd9dc990
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 18:44:13 +00:00
TreeHugger Robot
6c68f5019f Merge "IMMS: Make IMMS PendingIntents immutable" into qt-dev am: 5ccf55eb8a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19119301

Change-Id: I6489df9d2f15ab52752fd26990d6f1dc24dbc0fb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 18:28:04 +00:00
TreeHugger Robot
5ccf55eb8a Merge "IMMS: Make IMMS PendingIntents immutable" into qt-dev 2022-07-01 18:13:46 +00:00
Steven Moreland
8b0242a232 Parcel: recycle recycles am: b5c79e141a am: 2b5f7f71c3
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19101007

Change-Id: Iedbf1334020ece5034ec3005f97b79a71a73cb78
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 18:10:48 +00:00
Steven Moreland
2b5f7f71c3 Parcel: recycle recycles am: b5c79e141a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19101007

Change-Id: Ibd1008515a0d4bc9b919ef13a563de502c332c12
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 17:54:27 +00:00
Linus Tufvesson
838fc349b6 Merge "Make Activites touch opaque - DO NOT MERGE" into rvc-dev 2022-07-01 08:53:41 +00:00
Manjeet Rulhania
50d343c656 Remove package name from SafetyNet logs
Bug: 213323615
Test: AppSecurityTests
Change-Id: Ia2be2b1e32dc0b75c352bc15219f4c4de9abb45a
Merged-In: I993832e148636f1795ffe393c6dc74a08b9442f8
Merged-In: I8f823487ca16861a35135cfc3383fa2ce8258017
Merged-In: I4b61d13256ce0bfb8fc9d21db52ee78ce2097f14
2022-06-30 22:33:55 +00:00
Manjeet Rulhania
bbe2a11827 Remove package name from SafetyNet logs
Bug: 213323615
Test: AppSecurityTests
Change-Id: I993832e148636f1795ffe393c6dc74a08b9442f8
Merged-In: I8f823487ca16861a35135cfc3383fa2ce8258017
Merged-In: I4b61d13256ce0bfb8fc9d21db52ee78ce2097f14
2022-06-30 22:33:32 +00:00
Adrian Roos
2b85982616 IMMS: Make IMMS PendingIntents immutable
Fixes: 154913391
Test: n/a
Change-Id: I34a95732ef3e7c20d6549b57230c11f0c3db04d6
Merged-In: I34a95732ef3e7c20d6549b57230c11f0c3db04d6
(cherry picked from commit d4b625994f)
(cherry picked from commit 6842f03c9d)
2022-06-29 17:33:52 +00:00
Songchun Fan
1cad7c909a Merge changes from topic "revert-16575908-dont_abandon_child_qt_dev-VVMFNIYZZO" into qt-dev am: 63257e0e97 am: 78bdbdd22e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092695

Change-Id: I47264e315e0085cf65b680452e8585651de4de19
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:36:42 +00:00
Songchun Fan
9d8f5dfc20 [automerger skipped] [RESTRICT AUTOMERGE] Revert "Revert "Revert "[pm] remove old stage dirs on low storage""" am: dde06fe41d -s ours am: 269e4e0e32 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092695

Change-Id: I7a5eeaced6e9c71553fa370dfc83c1ffaa0dafcb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:36:28 +00:00
Songchun Fan
75365b4139 [automerger skipped] Merge "[RESTRICT AUTOMERGE] Revert "Persist destroyed staged sessions until they are cleaned up"" into qt-dev am: 650eb0cc65 am: 318cccd37d -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092213

Change-Id: I664b4297458f60c98ac5df28307c9bbffc517f33
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:36:08 +00:00
Songchun Fan
332e015554 [automerger skipped] [RESTRICT AUTOMERGE] Revert "Persist destroyed staged sessions until they are cleaned up" am: 07d74c4c28 am: 9a00a3d2a8 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092213

Change-Id: I9a8fe839957a612e71545f9c01a6286749b0d889
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:35:52 +00:00
Songchun Fan
78bdbdd22e Merge changes from topic "revert-16575908-dont_abandon_child_qt_dev-VVMFNIYZZO" into qt-dev am: 63257e0e97
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092695

Change-Id: I831a7c6e8971d8998bb48326ef890c23dd8a97ab
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:12:56 +00:00
Songchun Fan
269e4e0e32 [automerger skipped] [RESTRICT AUTOMERGE] Revert "Revert "Revert "[pm] remove old stage dirs on low storage""" am: dde06fe41d -s ours
am skip reason: skipped by user schfan

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19092695

Change-Id: I3750cf18bd2049c430dcf292cc19db365f3fc26f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-29 01:12:54 +00:00