summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorMustafa Acer <meacer@google.com>2021-03-11 18:38:27 +0000
committerMustafa Emre Acer <meacer@google.com>2021-03-23 16:24:41 +0000
commit6cebc2f2ac13fcc4430d3180195694761710f9a2 (patch)
tree630af802dc7e4be9ffacb2c2aee86fe61c3c2906 /tools/aapt2/java/JavaClassGenerator_test.cpp
parent934f10e67d7d45c966d58e805d90bf263e41607d (diff)
Add a new permission for external time sources
This CL adds a new permission called SUGGEST_EXTERNAL_TIME that gates TimeManager.suggestExternalTime calls. The new permission is marked as 'privileged' as protection level. This could result in third party apps preinstalled on the system image to potentially get this permission. This is OK for the following reasons: - OEM coordination is needed to grant 3P apps this permission, so adding "privileged" doesn't introduce significant risk. - This permission/API doesn't guarantee that the suggested timestamp will immediately be used as the new system timestamp. The system must be configured so that the external time source has a higher priority than other time sources (e.g. GNSS) for the external time suggestion to be used. This configuration is also done by the OEM. That introduces significant roadblock for a malicious app to do anything useful with this permission. - More importantly, apps can set system time directly using TimeManager.setTime() which requires SET_TIME permission. This permission is also signature|privileged, so this change is consistent with it. Bug: 157504928, 177079827 CTS-Coverage-Bug: 182275086 Test: atest android.app.time Change-Id: I0098ab7565b647fb220d39575f0616d2a47bdc89
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions