mirror of
https://github.com/chararomandroid/android_device_samsung_a20
synced 2026-08-23 12:35:33 -04:00
universal7885: Address SELinux denials
* Now boots with enforcing kernel
This commit is contained in:
parent
c7f80dea23
commit
7329c87196
17 changed files with 50 additions and 30 deletions
|
|
@ -33,3 +33,7 @@ type pm_qos_device, dev_type;
|
|||
type radio_qos_device, dev_type;
|
||||
type ssp_device, dev_type;
|
||||
type vendor_radio_device, dev_type;
|
||||
|
||||
type drm_device, dev_type;
|
||||
type custom_loop_device, dev_type;
|
||||
|
||||
|
|
|
|||
|
|
@ -152,6 +152,12 @@
|
|||
|
||||
# camera
|
||||
/dev/m2m1shot_scaler0 u:object_r:m2m1shot_device:s0
|
||||
|
||||
# DRM
|
||||
/dev/s5p-smem u:object_r:drm_device:s0
|
||||
|
||||
# Loop
|
||||
/dev/block/loop* u:object_r:custom_loop_device:s0
|
||||
|
||||
# usb
|
||||
/dev/android_ssusbcon(/.*)? u:object_r:usb_device:s0
|
||||
|
|
@ -212,7 +218,7 @@
|
|||
/(vendor|system/vendor)/bin/hw/android\.hardware\.usb@[0-9]\.[0-9]-service\.exynos7884B u:object_r:hal_usb_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.samsung\.hardware\.gnss@[0-9]\.[0-9]-service u:object_r:hal_gnss_default_exec:s0
|
||||
/(vendor|system/vendor)/firmware(/.*)? u:object_r:vendor_firmware_file:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.sensors@2.1-service\.samsung-multihal u:object_r:hal_sensors_default_exec:s0
|
||||
|
||||
|
||||
# SamsungParts
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.eureka\.hardware\.battery@1\.0-service u:object_r:hal_battery_default_exec:s0
|
||||
|
|
|
|||
|
|
@ -12,3 +12,4 @@ allow hal_battery_default sysfs_battery_writable:file rw_file_perms;
|
|||
allow hal_battery_default sysfs_sec_switch_writable:dir { search };
|
||||
allow hal_battery_default sysfs_battery_writable:dir { search };
|
||||
allow hal_battery_default sysfs_battery:dir { search };
|
||||
allow hal_battery_default sysfs_virtual:dir { search };
|
||||
|
|
|
|||
|
|
@ -19,3 +19,5 @@ allow hal_drm_widevine vendor_data_file:file create_file_perms;
|
|||
|
||||
allow hal_drm_widevine cpk_efs_file:file r_file_perms;
|
||||
allow hal_drm_widevine efs_file:dir search;
|
||||
|
||||
allow hal_drm_widevine drm_device:chr_file { read write open ioctl };
|
||||
|
|
|
|||
|
|
@ -7,3 +7,5 @@ hwbinder_use(hal_flashlight_default);
|
|||
get_prop(hal_flashlight_default, hwservicemanager_prop);
|
||||
allow hal_flashlight_default sysfs_flashlight:file { read open write getattr };
|
||||
allow hal_flashlight_default sysfs_flashlight:dir search;
|
||||
|
||||
allow hal_flashlight_default sysfs_virtual:dir { search };
|
||||
|
|
|
|||
|
|
@ -5,5 +5,5 @@ init_daemon_domain(hal_gpu_default);
|
|||
|
||||
hwbinder_use(hal_gpu_default);
|
||||
get_prop(hal_gpu_default, hwservicemanager_prop)
|
||||
allow system_app sysfs_gpu_tmu:file { read open write getattr };
|
||||
allow system_app sysfs_gpu_tmu:dir search;
|
||||
allow hal_gpu_default sysfs_gpu_tmu:file { read open write getattr };
|
||||
allow hal_gpu_default sysfs_gpu_tmu:dir search;
|
||||
|
|
|
|||
|
|
@ -7,3 +7,4 @@ allow hal_keymaster_default mnt_vendor_file:dir search;
|
|||
allow hal_keymaster_default efs_file:dir search;
|
||||
teegris_use(hal_keymaster_default)
|
||||
allow hal_keymaster_default prov_efs_file:file r_file_perms;
|
||||
allow hal_keymaster_default prov_efs_file:dir search;
|
||||
|
|
|
|||
|
|
@ -5,3 +5,5 @@ allow hal_wifi_default conn_vendor_data_file:dir search;
|
|||
allow hal_wifi_default conn_vendor_data_file:file rw_file_perms;
|
||||
allow hal_wifi_default wifi_vendor_data_file:dir search;
|
||||
|
||||
get_prop(hal_wifi_default, persist_vendor_debug_wifi_prop)
|
||||
|
||||
|
|
|
|||
3
universal7885-common/sepolicy/vendor/init.te
vendored
3
universal7885-common/sepolicy/vendor/init.te
vendored
|
|
@ -55,3 +55,6 @@ allow init proc_last_kmsg:file setattr;
|
|||
allow init mnt_vendor_file:dir mounton;
|
||||
|
||||
unix_socket_connect(init, property, rild)
|
||||
|
||||
get_prop(init, vendor_radio_prop)
|
||||
get_prop(init, radio_prop)
|
||||
|
|
|
|||
|
|
@ -16,3 +16,5 @@ allow kernel block_device:dir search;
|
|||
|
||||
allow kernel sysfs_sec_key:dir search;
|
||||
r_dir_file(kernel, sysfs_virtual)
|
||||
|
||||
allow kernel loop_device:blk_file { create setattr };
|
||||
|
|
|
|||
2
universal7885-common/sepolicy/vendor/rild.te
vendored
2
universal7885-common/sepolicy/vendor/rild.te
vendored
|
|
@ -93,5 +93,3 @@ allow rild hal_audio_default:file r_file_perms;
|
|||
|
||||
# hwservice
|
||||
add_hwservice(rild, rild_hwservice)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -10,3 +10,15 @@ allow system_app sysfs_battery_info:dir { search };
|
|||
allow system_app sysfs_battery_info:file { read open getattr };
|
||||
|
||||
r_dir_file(system_app, sysfs_battery_info)
|
||||
|
||||
# SamsungParts
|
||||
#
|
||||
allow system_app hal_battery_hwservice:hwservice_manager find;
|
||||
allow system_app hal_flashlight_hwservice:hwservice_manager find;
|
||||
allow system_app hal_selinux_hwservice:hwservice_manager find;
|
||||
allow system_app hal_gpu_hwservice:hwservice_manager find;
|
||||
|
||||
allow system_app hal_battery_default:binder call;
|
||||
allow system_app hal_flashlight_default:binder call;
|
||||
allow system_app hal_selinux_default:binder call;
|
||||
allow system_app hal_gpu_default:binder call;
|
||||
|
|
|
|||
Loading…
Reference in a new issue