From 6d57b494c0e1d88b00ae26fa59b3cf4f4a58da9b Mon Sep 17 00:00:00 2001 From: Henry Tung Date: Fri, 6 Dec 2019 15:59:58 +0800 Subject: [PATCH] Create new system property type for Factory OTA could write system property Due to Factory OTA client install in product partition but it also declare coredomian in its sepolicy setting. That will let Factory OTA unable to find a property type could write system property. But now Factory OTA have a restore NFC wake function need to write system property for communicate with bootloader. So we need to create a new property type in system framework which could allow Factory OTA client to write system property. Bug: 145178094 Test: Manual Change-Id: Ic549cc939893ec67a46bf28a23ebeb9f9b81bd0b --- prebuilts/api/29.0/private/compat/28.0/28.0.ignore.cil | 1 + prebuilts/api/29.0/public/property.te | 2 ++ private/compat/28.0/28.0.ignore.cil | 1 + public/property.te | 2 ++ 4 files changed, 6 insertions(+) diff --git a/prebuilts/api/29.0/private/compat/28.0/28.0.ignore.cil b/prebuilts/api/29.0/private/compat/28.0/28.0.ignore.cil index 98c4b9c9b..ed3671f11 100644 --- a/prebuilts/api/29.0/private/compat/28.0/28.0.ignore.cil +++ b/prebuilts/api/29.0/private/compat/28.0/28.0.ignore.cil @@ -49,6 +49,7 @@ dynamic_system_prop face_service face_vendor_data_file + sota_prop fastbootd flags_health_check flags_health_check_exec diff --git a/prebuilts/api/29.0/public/property.te b/prebuilts/api/29.0/public/property.te index e166c000e..cea50aca0 100644 --- a/prebuilts/api/29.0/public/property.te +++ b/prebuilts/api/29.0/public/property.te @@ -44,6 +44,7 @@ type dumpstate_options_prop, property_type; type dumpstate_prop, property_type, core_property_type; type dynamic_system_prop, property_type; type exported_secure_prop, property_type; +type sota_prop, property_type; type ffs_prop, property_type, core_property_type; type fingerprint_prop, property_type, core_property_type; type firstboot_prop, property_type; @@ -412,6 +413,7 @@ compatible_property_only(` -exported_vold_prop -exported_wifi_prop -extended_core_property_type + -sota_prop -ffs_prop -fingerprint_prop -firstboot_prop diff --git a/private/compat/28.0/28.0.ignore.cil b/private/compat/28.0/28.0.ignore.cil index 6fc86deff..222fa7b8d 100644 --- a/private/compat/28.0/28.0.ignore.cil +++ b/private/compat/28.0/28.0.ignore.cil @@ -51,6 +51,7 @@ dynamic_system_prop face_service face_vendor_data_file + sota_prop fastbootd flags_health_check flags_health_check_exec diff --git a/public/property.te b/public/property.te index f4a9575d0..e84c36a6c 100644 --- a/public/property.te +++ b/public/property.te @@ -127,6 +127,7 @@ system_public_prop(exported_pm_prop) system_public_prop(exported_radio_prop) system_public_prop(exported_system_radio_prop) system_public_prop(exported_wifi_prop) +system_public_prop(sota_prop) system_public_prop(hwservicemanager_prop) system_public_prop(logd_prop) system_public_prop(logpersistd_logging_prop) @@ -595,6 +596,7 @@ compatible_property_only(` -exported_vold_prop -exported_wifi_prop -extended_core_property_type + -sota_prop -ffs_prop -fingerprint_prop -firstboot_prop