display-dump: sepolicy for new primary display dump
Bug: 376426334 Test: adb bugreport Test: adb shell /vendor/bin/dump/dump_*_display Test: adb shell /vendor/bin/dump/dump_*_second_display Flag: EXEMPT bugfix Change-Id: I3b1d1f46ddea4882f028d9314cfd174371039925
This commit is contained in:
15
display/sepolicy/pixel/dump_display.te
Normal file
15
display/sepolicy/pixel/dump_display.te
Normal file
@@ -0,0 +1,15 @@
|
||||
# Display (dump for bugreport)
|
||||
pixel_bugreport(dump_pixel_display)
|
||||
|
||||
allow dump_pixel_display sysfs_display:file r_file_perms;
|
||||
allow dump_pixel_display vendor_displaycolor_service:service_manager find;
|
||||
binder_call(dump_pixel_display, hal_graphics_composer_default)
|
||||
allow dump_pixel_display vendor_dumpsys:file execute_no_trans;
|
||||
allow dump_pixel_display vendor_shell_exec:file execute_no_trans;
|
||||
|
||||
userdebug_or_eng(`
|
||||
allow dump_pixel_display vendor_dri_debugfs:dir r_dir_perms;
|
||||
allow dump_pixel_display vendor_dri_debugfs:file r_file_perms;
|
||||
')
|
||||
vndbinder_use(dump_pixel_display)
|
||||
|
||||
11
display/sepolicy/pixel/dump_display_userdebug.te
Normal file
11
display/sepolicy/pixel/dump_display_userdebug.te
Normal file
@@ -0,0 +1,11 @@
|
||||
# Display eng/userdebug (dump for bugreport)
|
||||
pixel_bugreport(dump_pixel_display_userdebug)
|
||||
|
||||
userdebug_or_eng(`
|
||||
allow dump_pixel_display_userdebug vendor_toolbox_exec:file execute_no_trans;
|
||||
allow dump_pixel_display_userdebug vendor_log_file:dir search;
|
||||
allow dump_pixel_display_userdebug vendor_hwc_log_file:dir r_dir_perms;
|
||||
allow dump_pixel_display_userdebug vendor_hwc_log_file:file r_file_perms;
|
||||
allow dump_pixel_display_userdebug debugfs_tracing_instances:dir search;
|
||||
allow dump_pixel_display_userdebug debugfs_tracing_instances:file r_file_perms;
|
||||
')
|
||||
3
display/sepolicy/pixel/file.te
Normal file
3
display/sepolicy/pixel/file.te
Normal file
@@ -0,0 +1,3 @@
|
||||
type vendor_hwc_log_file, file_type, data_file_type;
|
||||
type vendor_dri_debugfs, fs_type, debugfs_type;
|
||||
|
||||
5
display/sepolicy/pixel/file_contexts
Normal file
5
display/sepolicy/pixel/file_contexts
Normal file
@@ -0,0 +1,5 @@
|
||||
/vendor/bin/dump/dump_display_userdebug\.sh u:object_r:dump_pixel_display_userdebug_exec:s0
|
||||
/vendor/bin/dump/dump_pixel_display u:object_r:dump_pixel_display_exec:s0
|
||||
|
||||
/data/vendor/log/hwc(/.*)? u:object_r:vendor_hwc_log_file:s0
|
||||
|
||||
3
display/sepolicy/pixel/genfs_contexts
Normal file
3
display/sepolicy/pixel/genfs_contexts
Normal file
@@ -0,0 +1,3 @@
|
||||
|
||||
genfscon debugfs /dri/0/crtc- u:object_r:vendor_dri_debugfs:s0
|
||||
genfscon sysfs /module/drm/parameters/debug u:object_r:sysfs_display:s0
|
||||
3
display/sepolicy/pixel/hal_graphics_composer_default.te
Normal file
3
display/sepolicy/pixel/hal_graphics_composer_default.te
Normal file
@@ -0,0 +1,3 @@
|
||||
allow hal_graphics_composer_default dump_pixel_display:fifo_file { append write };
|
||||
allow hal_graphics_composer_default dump_pixel_display:fd use;
|
||||
|
||||
2
display/sepolicy/pixel/vndservice.te
Normal file
2
display/sepolicy/pixel/vndservice.te
Normal file
@@ -0,0 +1,2 @@
|
||||
type vendor_displaycolor_service, vndservice_manager_type;
|
||||
|
||||
2
display/sepolicy/pixel/vndservice_contexts
Normal file
2
display/sepolicy/pixel/vndservice_contexts
Normal file
@@ -0,0 +1,2 @@
|
||||
displaycolor u:object_r:vendor_displaycolor_service:s0
|
||||
|
||||
Reference in New Issue
Block a user