diff --git a/non_plat/file_contexts b/non_plat/file_contexts index b8d9a2b..7abec2e 100644 --- a/non_plat/file_contexts +++ b/non_plat/file_contexts @@ -611,3 +611,6 @@ /vendor/lib(64)?/libpq_prot\.so u:object_r:same_process_hal_file:s0 /vendor/lib(64)?/libladder\.so u:object_r:same_process_hal_file:s0 + +/vendor/bin/hw/vendor\.mediatek\.hardware\.dumpstate@1\.0-service u:object_r:hal_dumpstate_impl_exec:s0 +/vendor/bin/aeev u:object_r:aee_aedv_exec:s0 diff --git a/non_plat/hal_dumpstate_impl.te b/non_plat/hal_dumpstate_impl.te new file mode 100644 index 0000000..59a8fc8 --- /dev/null +++ b/non_plat/hal_dumpstate_impl.te @@ -0,0 +1,11 @@ +type hal_dumpstate_impl, domain; +hal_server_domain(hal_dumpstate_impl, hal_dumpstate) + +type hal_dumpstate_impl_exec, exec_type, vendor_file_type, file_type; +init_daemon_domain(hal_dumpstate_impl) + +allow hal_dumpstate_impl vendor_shell_exec:file rx_file_perms; +allow hal_dumpstate_impl vendor_toolbox_exec:file rx_file_perms; + +allow hal_dumpstate_impl aee_exp_vendor_file:file create_file_perms; +allow hal_dumpstate_impl aee_exp_vendor_file:dir create_dir_perms; diff --git a/plat_private/vendor_shell.te b/plat_private/vendor_shell.te new file mode 100644 index 0000000..46903b0 --- /dev/null +++ b/plat_private/vendor_shell.te @@ -0,0 +1,5 @@ +# ============================================== +# MTK Policy Rule +# ============================================= +# Purpose : allow vendor_shell to run aeev +allow vendor_shell aee_aedv_exec:file execute_no_trans;