From b05833237caf7e50e1b4b7879cc29ce182eeac7a Mon Sep 17 00:00:00 2001 From: Aaron Tsai Date: Thu, 23 May 2024 08:40:37 +0000 Subject: [PATCH] Add permission for setting gril property 05-22 18:00:40.443 948 948 I auditd : type=1400 audit(0.0:854): avc: denied { write } for comm="radioext@1.0-se" name="property_service" dev="tmpfs" ino=851 scontext=u:r:hal_radioext_default:s0 tcontext=u:object_r:property_socket:s0 tclass=sock_file permissive=0 Bug: 343012301 Bug: 203824024 Test: manual test Flag: EXEMPT bugfix Change-Id: Ie873e186d3eda618ba832164d9c9713b410977d2 --- whitechapel_pro/hal_radioext_default.te | 1 + whitechapel_pro/property.te | 1 + whitechapel_pro/property_contexts | 3 +++ 3 files changed, 5 insertions(+) diff --git a/whitechapel_pro/hal_radioext_default.te b/whitechapel_pro/hal_radioext_default.te index fb6bc03d..7e21da86 100644 --- a/whitechapel_pro/hal_radioext_default.te +++ b/whitechapel_pro/hal_radioext_default.te @@ -4,6 +4,7 @@ init_daemon_domain(hal_radioext_default) hwbinder_use(hal_radioext_default) get_prop(hal_radioext_default, hwservicemanager_prop) +set_prop(hal_radioext_default, vendor_gril_prop) add_hwservice(hal_radioext_default, hal_radioext_hwservice) binder_call(hal_radioext_default, grilservice_app) diff --git a/whitechapel_pro/property.te b/whitechapel_pro/property.te index 559511a0..98fd4534 100644 --- a/whitechapel_pro/property.te +++ b/whitechapel_pro/property.te @@ -4,6 +4,7 @@ vendor_internal_prop(vendor_modem_prop) vendor_internal_prop(vendor_persist_config_default_prop) vendor_internal_prop(vendor_cbd_prop) vendor_internal_prop(vendor_rild_prop) +vendor_internal_prop(vendor_gril_prop) vendor_internal_prop(vendor_carrier_prop) vendor_internal_prop(vendor_ssrdump_prop) vendor_internal_prop(vendor_wifi_version) diff --git a/whitechapel_pro/property_contexts b/whitechapel_pro/property_contexts index 0ff833e8..9f1747b5 100644 --- a/whitechapel_pro/property_contexts +++ b/whitechapel_pro/property_contexts @@ -38,6 +38,9 @@ vendor.sys.rild_reset u:object_r:vendor_rild_prop:s0 persist.vendor.radio. u:object_r:vendor_rild_prop:s0 ro.vendor.config.build_carrier u:object_r:vendor_carrier_prop:s0 +# for GRIL +vendor.gril. u:object_r:vendor_gril_prop:s0 + persist.vendor.config. u:object_r:vendor_persist_config_default_prop:s0 # SSR Detector