diff --git a/Android.mk b/Android.mk index bd2bd5698..8220fd59f 100644 --- a/Android.mk +++ b/Android.mk @@ -511,6 +511,8 @@ LOCAL_REQUIRED_MODULES += \ odm_seapp_contexts \ odm_property_contexts \ odm_property_contexts_test \ + odm_service_contexts \ + odm_service_contexts_test \ odm_hwservice_contexts \ odm_hwservice_contexts_test \ odm_mac_permissions.xml diff --git a/contexts/Android.bp b/contexts/Android.bp index 82f42ba2f..d5cd8aef6 100644 --- a/contexts/Android.bp +++ b/contexts/Android.bp @@ -277,6 +277,15 @@ service_contexts { recovery_available: true, } +service_contexts { + name: "odm_service_contexts", + srcs: [ + ":service_contexts_files{.odm}", + ], + device_specific: true, + recovery_available: true, +} + keystore2_key_contexts { name: "plat_keystore2_key_contexts", srcs: [":keystore2_key_contexts_files{.plat_private}"], @@ -515,6 +524,12 @@ service_contexts_test { sepolicy: ":precompiled_sepolicy", } +service_contexts_test { + name: "odm_service_contexts_test", + srcs: [":odm_service_contexts"], + sepolicy: ":precompiled_sepolicy", +} + vndservice_contexts_test { name: "vndservice_contexts_test", srcs: [":vndservice_contexts"], diff --git a/private/file_contexts b/private/file_contexts index 951c9b5b5..4deecf714 100644 --- a/private/file_contexts +++ b/private/file_contexts @@ -443,13 +443,14 @@ /odm/etc/selinux/precompiled_sepolicy u:object_r:sepolicy_file:s0 /odm/etc/selinux/precompiled_sepolicy\.plat_and_mapping\.sha256 u:object_r:sepolicy_file:s0 -/(odm|vendor/odm)/etc/selinux/odm_sepolicy\.cil u:object_r:sepolicy_file:s0 +/(odm|vendor/odm)/etc/selinux/odm_sepolicy\.cil u:object_r:sepolicy_file:s0 /(odm|vendor/odm)/etc/selinux/odm_file_contexts u:object_r:file_contexts_file:s0 /(odm|vendor/odm)/etc/selinux/odm_seapp_contexts u:object_r:seapp_contexts_file:s0 /(odm|vendor/odm)/etc/selinux/odm_property_contexts u:object_r:property_contexts_file:s0 +/(odm|vendor/odm)/etc/selinux/odm_service_contexts u:object_r:vendor_service_contexts_file:s0 /(odm|vendor/odm)/etc/selinux/odm_hwservice_contexts u:object_r:hwservice_contexts_file:s0 -/(odm|vendor/odm)/etc/selinux/odm_keystore2_key_contexts u:object_r:keystore2_key_contexts_file:s0 -/(odm|vendor/odm)/etc/selinux/odm_mac_permissions\.xml u:object_r:mac_perms_file:s0 +/(odm|vendor/odm)/etc/selinux/odm_keystore2_key_contexts u:object_r:keystore2_key_contexts_file:s0 +/(odm|vendor/odm)/etc/selinux/odm_mac_permissions\.xml u:object_r:mac_perms_file:s0 ############################# # Product files