device_google_gs101/whitechapel/vendor/google/dump_power.te
Spade Lee c025f4915b sepolicy: allow dump_power to read debugfs
11-01 11:59:42.836 11781 11781 W dump_power: type=1400 audit(0.0:46): avc:  denied  { search } for  name="usb" dev="debugfs" ino=2059 scontext=u:r:dump_power:s0 tcontext=u:object_r:vendor_usb_debugfs:s0 tclass=dir permissive=0
11-01 11:59:42.844 11781 11781 W dump_power: type=1400 audit(0.0:47): avc:  denied  { search } for  name="google_battery" dev="debugfs" ino=18509 scontext=u:r:dump_power:s0 tcontext=u:object_r:vendor_battery_debugfs:s0 tclass=dir permissive=0
11-01 11:59:42.844 11781 11781 W dump_power: type=1400 audit(0.0:48): avc:  denied  { read } for  name="maxfg" dev="debugfs" ino=16428 scontext=u:r:dump_power:s0 tcontext=u:object_r:vendor_maxfg_debugfs:s0 tclass=dir permissive=0
11-01 11:59:42.844 11781 11781 W dump_power: type=1400 audit(0.0:49): avc:  denied  { read } for  name="/" dev="debugfs" ino=1 scontext=u:r:dump_power:s0 tcontext=u:object_r:debugfs:s0 tclass=dir permissive=0
11-01 11:59:42.844 11781 11781 W dump_power: type=1400 audit(0.0:50): avc:  denied  { read } for  name="/" dev="debugfs" ino=1 scontext=u:r:dump_power:s0 tcontext=u:object_r:debugfs:s0 tclass=dir permissive=0
11-01 11:59:42.844 11781 11781 W dump_power: type=1400 audit(0.0:51): avc:  denied  { read } for  name="/" dev="debugfs" ino=1 scontext=u:r:dump_power:s0 tcontext=u:object_r:debugfs:s0 tclass=dir permissive=0

Bug: 376080915
Test: adb bugreport without audit
Flag: EXEMPT bugfix
Change-Id: I7ae11300cd45f7e8c05c0dcf46d5dfda5c777400
Signed-off-by: Spade Lee <spadelee@google.com>
2024-11-01 18:05:40 +00:00

24 lines
999 B
Text

# Allow dumpstate to execute dump_power
pixel_bugreport(dump_power);
allow dump_power sysfs_acpm_stats:dir r_dir_perms;
allow dump_power sysfs_acpm_stats:file r_file_perms;
allow dump_power sysfs_cpu:file r_file_perms;
allow dump_power sysfs_wlc:file r_file_perms;
allow dump_power sysfs_wlc:dir search;
allow dump_power sysfs_batteryinfo:dir r_dir_perms;
allow dump_power sysfs_batteryinfo:file r_file_perms;
allow dump_power logbuffer_device:chr_file r_file_perms;
allow dump_power mitigation_vendor_data_file:dir r_dir_perms;
allow dump_power mitigation_vendor_data_file:file r_file_perms;
allow dump_power sysfs_bcl:dir r_dir_perms;
allow dump_power sysfs_bcl:file r_file_perms;
userdebug_or_eng(`
r_dir_file(dump_power, vendor_battery_debugfs)
r_dir_file(dump_power, vendor_maxfg_debugfs)
r_dir_file(dump_power, vendor_charger_debugfs)
r_dir_file(dump_power, vendor_votable_debugfs)
allow dump_power debugfs:dir r_dir_perms;
allow dump_power vendor_usb_debugfs:dir { search };
')