From 84105de0efbd4d3bdf530850862ff0e3607efd16 Mon Sep 17 00:00:00 2001 From: Kelvin Zhang Date: Wed, 9 Sep 2020 09:22:39 -0400 Subject: [PATCH] Grant gmscore permission to read virtual ab properties Bug: 168059475 Test: Serve an update over gmscore Change-Id: Iefd88f4189b50ee68ee09bcb5a20556ba4ea3e1a --- private/gmscore_app.te | 4 ++++ private/property_contexts | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/private/gmscore_app.te b/private/gmscore_app.te index 502216086..ff7444fb7 100644 --- a/private/gmscore_app.te +++ b/private/gmscore_app.te @@ -127,3 +127,7 @@ allow gmscore_app anr_data_file:file r_file_perms; # b/148974132: com.android.vending needs this allow gmscore_app priv_app:tcp_socket { read write }; + +# b/168059475 Allow GMSCore to read Virtual AB properties to determine +# if device supports VAB. +get_prop(gmscore_app, virtual_ab_prop) diff --git a/private/property_contexts b/private/property_contexts index 478570710..d65d1d685 100644 --- a/private/property_contexts +++ b/private/property_contexts @@ -235,8 +235,8 @@ sys.boot_from_charger_mode u:object_r:charger_status_prop:s0 exact int ro.enable_boot_charger_mode u:object_r:charger_config_prop:s0 exact bool # Virtual A/B properties -ro.virtual_ab.enabled u:object_r:virtual_ab_prop:s0 -ro.virtual_ab.retrofit u:object_r:virtual_ab_prop:s0 +ro.virtual_ab.enabled u:object_r:virtual_ab_prop:s0 exact bool +ro.virtual_ab.retrofit u:object_r:virtual_ab_prop:s0 exact bool ro.product.ab_ota_partitions u:object_r:ota_prop:s0 exact string # Property to set/clear the warm reset flag after an OTA update.