Verify permissions for all activities in the Task

Loop over all activities in the task and verify their
display permissions using the caller's identity before moving the task.
If any activity fails the check, a SecurityException is thrown.

Bug: 527035781
Bug: 527036864
Bug: 527039128
Test: ActivityTaskManagerServiceTests
Flag: EXEMPT CVE_FIX
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:12d5de2a0e06beb34abce054ab0e8897135da323
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:2f47d65518c42eff6e4cf7b6faf7846cc37ac585
Merged-In: Ifcbb9b08399273995a6da358e438e1335acc5f32
Change-Id: Ifcbb9b08399273995a6da358e438e1335acc5f32
1 file changed