device_google_gs201/whitechapel_pro/hal_sensors_default.te
Rick Chen e22b188d9d sensors: Move USF related sepolicy to gs-common.
Bug: 305120274
Test: Compile pass. Flash the build to WHI_PRO devices and no sensor
      related avc denied log.
Change-Id: I48d959d439565e9c31ce83812bf29b6d8025c35b
Signed-off-by: Rick Chen <rickctchen@google.com>
2023-11-07 06:49:05 +00:00

27 lines
939 B
Text

#
# USF sensor HAL SELinux type enforcements.
#
# Allow reading of camera persist files.
r_dir_file(hal_sensors_default, persist_camera_file)
# Allow access to the files of CDT information.
r_dir_file(hal_sensors_default, sysfs_chosen)
# Allow display_info_service access to the backlight driver.
allow hal_sensors_default sysfs_write_leds:file rw_file_perms;
# Allow access for dynamic sensor properties.
get_prop(hal_sensors_default, vendor_dynamic_sensor_prop)
# Allow access to raw HID devices for dynamic sensors.
allow hal_sensors_default hidraw_device:chr_file rw_file_perms;
# Allow sensor HAL to access the display service HAL
allow hal_sensors_default hal_pixel_display_service:service_manager find;
# Allow sensor HAL to access the graphics composer.
binder_call(hal_sensors_default, hal_graphics_composer_default)
# Allow access to the power supply files for MagCC.
allow hal_sensors_default sysfs_wlc:dir r_dir_perms;