Commit Graph

26 Commits

Author SHA1 Message Date
Yohei Yukawa
6a571bf6c6 Allow com.android.settings to have CONTROL_UI_TRACING (2nd try)
This CL allows

  com.android.settings

to have a "signature|privileged" permission

  android.permission.CONTROL_UI_TRACING

permission.  This permission will be used for QS DevelopmentTiles to
continue being allowed to access WM/IME tracing IPCs.

Bug: 172444310
Test: cf_x86_64_phone-userdebug still boots up
Test: cf_x86_64_auto-userdebug still boots up
Change-Id: I9aa69247f02447f2454e42e3625f0ed764991edf
2022-07-25 18:38:26 +09:00
Luigi Zevola
afa3a4357b Revert "Allow com.android.settings to have CONTROL_UI_TRACING"
Revert "Grant CONTROL_UI_TRACING permission to Settings app"

Revert submission 19391474-yukawa-b172444310

Reason for revert: b/239969206
Reverted Changes:
I34bc22392:Allow com.android.settings to have CONTROL_UI_TRAC...
I2165ce38e:Grant CONTROL_UI_TRACING permission to Settings ap...

Change-Id: I230b9650a539ce549169276cb4605a68fc007205
2022-07-22 20:38:01 +00:00
Yohei Yukawa
5da5eac4b5 Allow com.android.settings to have CONTROL_UI_TRACING
This CL allows

  com.android.settings

to have a "signature|privileged" permission

  android.permission.CONTROL_UI_TRACING

permission.  This permission will be used for QS DevelopmentTiles to
continue being allowed to access WM/IME tracing IPCs.

Bug: 172444310
Test: the device still boots up
Change-Id: I34bc22392cb4fa233126b46fb979638c90a3c3c6
2022-07-21 20:33:00 -07:00
Marie Matheson
a4f204b385 Adds the SEND_SAFETY_CENTER_UPDATE privileged permission to the Settings app.
Test: atest SettingsUnitTests
Bug: 216076319
Change-Id: If079d10aa7e67f2f04676fe72eba1d2c7c1ec2d7
2022-01-25 18:35:29 +00:00
Jan Tomljanovic
c1f6071c2f Merge "Add privileged permission to the Settings app." 2022-01-24 12:55:19 +00:00
Jan Tomljanovic
3c897648e4 Add privileged permission to the Settings app.
Test: atest SettingsUnitTests
Bug: 208625216
Change-Id: Iad3474d56d499bf746edb07a56625bc2e607e492
2022-01-21 12:07:02 +00:00
Peiyong Lin
c7f625ffc7 Implement getGameModeInfo API.
The Game Dashboard needs to access the active game mode and the
available game modes of a given game in order to provide the UX. Instead
of doing two queries with two binder calls, implement a new API to
capture all GameMode related states of a given package.

Minor: Don't return UNSUPPORTED when querying available game modes,
change MANAGE_GAME_MODE permission to allow system apps to access the
APIs.

Bug: b/199920468
Test: atest GameManagerServiceTests
Test: atest GameManagerTests
Change-Id: I45d9c2df5bffd6496f97140e44d0ca5afeee71b1
2022-01-21 01:31:27 +00:00
Felipe Leme
71e1b819b8 Add missing privapp permission allowlist entries.
Bug: 179996437
Test: manual
Change-Id: I4b4eeceafecb48215be194861e8c261b47b3addb
2021-02-11 12:34:38 -08:00
Bo Hu
e54ab06710 Revert "Fix privapp permission allowlisting."
This reverts commit e391b19376.

Reason for revert: b/180009384

Test:
lunch sdk_gphone64_x86_64-userdebug
m -j
emulator



Change-Id: I5fb095019804ec732a11bccc9ad6ae43ccbb03b7
2021-02-11 17:20:06 +00:00
Hai Zhang
e391b19376 Fix privapp permission allowlisting.
The refactoring in S unintendedly introduced a change that allowed
signature|privileged to be granted to platform-signed privileged apps
without being in the allowlist XML, so we should revert to the old
behavior.

The refactoring was done in the hope that we can have one step that
handles privileged permission granting. However upon retrospection, we
have to do this in two separate steps because the privapp permission
allowlist should always be enforced first.

This change reverts to the old behavior by looking at both the current
code and the R source code, then extracts the privapp permission
enforcement as a separate step that happens first, to be used by both
signature and the new internal permission protection.

Also simplified the check about privileged permission, because vendor
privileged permission is always a privileged permission, as made sure
in PermissionInfo.fixProtectionLevel().

In the mean time, added the missing privapp permission allowlist entry
for Settings and RESTART_WIFI_SUBSYSTEM for device to boot.

Fixes: 179309876
Test: manual
Change-Id: I93cfe7a4621fc5ac65229d42c7a8ebd825ae8ae5
2021-02-10 16:40:00 -08:00
Edgar Wang
8a888b9745 Add READ_DREAM_STATE to the settings list
Settings application needs the previleged permission to
get AoD supression status by using PowerManager API

Bug: 173425264
Change-Id: I5da006b7c88dc36d3eefebc559f2a2f3ab50823f
Test: Manual & bootup device
2020-11-19 03:52:15 +00:00
Automerger Merge Worker
29097108e3 Merge "Add permissions for using PlatformCompat methods" am: 7202e904c9 am: 69ca2fcfa0 am: 9e28d2118f
Change-Id: Id9b74f1f74f3e4efaaa3e1657a64b7f8d229cc01
2020-02-06 14:18:16 +00:00
Andrei Onea
26559bcb40 Add permissions for using PlatformCompat methods
- READ_COMPAT_CHANGE_CONFIG is required to read the current state of the
config
- LOG_COMPAT_CHANGE is required to log the status of a compat change for
a package and/or uid to statsd
- OVERRIDE_COMPAT_CHANGE_CONFIG is required to add overrides

The permissions must be signature|privileged, as there are already
examples of code which this would not be sufficient (e.g.
MediaProvider).

This is a re-landing of https://r.android.com/1209240, which was
reverted due to http://b/142942524. The actual fix was done in
http://ag/10234812.


Bug: 142650523
Test: atest PlatformCompatTest
Test: atest PlatformCompatPermissionsTest
Change-Id: Ie9429477c9a1725b5cb67756787bf742038e5d2b
2020-02-06 12:22:42 +00:00
Zim
9eba4a9772 Whitelist privapp MANAGE_EXTERNAL_STORAGE permission
After adding MANAGE_EXTERNAL_STORAGE permission to several apps on the
system partition, we should whitelist them

Test: m
Bug: 144914977
Change-Id: Ia4401904e23193b8628071d6a2a6d789faf0ece5
2020-01-27 13:36:38 +00:00
Automerger Merge Worker
070e602547 Merge "Add new permissions" am: 62ace8c46a am: c0f9b27214 am: ec776dfda9
Change-Id: I8193a10bef4d829f41fd2609b571c9fa52365783
2020-01-06 21:35:59 +00:00
Neil Fuller
62ace8c46a Merge "Add new permissions" 2020-01-06 19:38:25 +00:00
Neil Fuller
09e8b7d841 Add new permissions
This adds new permissions required when setting the time /zone in
response to telephony signals and when setting the time / zone manually
along the lines of "principle of least privilege".

The intent is to later restrict the number of distinct processes that
can manipulate the device system clock / time zone property directly so
that all time changes go through the time / time zone detector services,
which can enforce policy, log the reasons for changes, and so on.

Bug: 140712361
Test: atest com.android.server.timedetector
Change-Id: Iabd3a5f449ad2ef2b6581475ef2535a4a8a88ef9
2019-12-19 11:11:48 +00:00
Yoshiaki Naka
79351c3fab Add READ_PRIVILEGED_PHONE_STATE to the settings whitelist
Settings application needs the previleged permission to retrieve UICC
card information by using Telephony Manager API.

Bug: 141256483
Test: Manual and SimStatusDialogControllerTest

Change-Id: I33d3bb1947d828e283ee62b7cd0936b8baf73acb
2019-12-12 15:09:46 +00:00
Howard Chen
c38989264e Fix boot failure on aosp_pixel-userdebug
Test: Boot test
Bug: 145904897
Change-Id: Icb83f886c8734aee8d77d455754ffa37336aa6d9
2019-12-10 12:42:15 +08:00
Bonian Chen
073cdcab42 [Settings] Change the ordering of permission
Move READ_PRIVILEGED_PHONE_STATE based on alphabet ordering.

Bug: 144960427
Test: build pass
Change-Id: Ia86e20afc87725b012014b272b5c2f570aa31ca8
2019-11-26 09:22:56 +08:00
Roshan Pius
40ff6d65cc Merge "Revert "privapps-permission: Make REQUEST_NETWORK_SCORES a privilged permission"" 2019-11-25 17:34:36 +00:00
Roshan Pius
8533a06a9d Revert "privapps-permission: Make REQUEST_NETWORK_SCORES a privilged permission"
This reverts commit 82f37f83a8.

Reason for revert: Wifi services no longer plan to be a separate
APK/process for mainline. Will instead become a jar loaded from Apex.

Bug: 145114247
Change-Id: I993dd4d35cc280afe6dc044fa1dee0ea268f9bca
2019-11-25 14:36:16 +00:00
Bonian Chen
ac5d9371aa [Settings] Permission to access ImsMmTelManager
Add READ_PRIVILEGED_PHONE_STATE permission

Bug: 140542283
Test: Manual
Change-Id: If88c6e3e1b5084a27c95b875bc74d28d0af908df
2019-11-08 17:13:41 +08:00
Roshan Pius
82f37f83a8 privapps-permission: Make REQUEST_NETWORK_SCORES a privilged permission
The wifi stack (signed by Google on non-Pixel devices) need to obtain this permission,
so it can no longer be signature only.

Bug: 113174748
Test: Compiles
Change-Id: Id9557a6d164a40698ee7d1e5926e56fd616868d0
2019-06-17 08:56:43 -07:00
jackqdyulei
8c360174f5 Update MediaSessions to add some methods
Also move drawable to settingslib

Bug: 126199571
Test: Build
Change-Id: I20d06c179b7cd67ef97cde1d04e26a120ffdd4ae
2019-02-27 13:24:37 -08:00
Anton Hansson
c32be24d36 Move Settings/SystemUI permissions to separate files
This makes it possible to move the permission around separately
from all the other permissions. This permission file is included
automatically when the respective app is included.

Bug: 110072687
Test: make
Change-Id: I91b30561d4a4000334ffbf3b98bb632d962f4b97
2018-12-17 15:04:34 +00:00