add sepolicy for dump TRICKLE/TEMP/DWELL defend config

type=1400 audit(0.0:12): avc: denied { read } for name="google,charger" dev="sysfs" ino=25880 scontext=u:r:hal_dumpstate_default:s0 tcontext=u:object_r:sysfs_batteryinfo:s0 tclass=dir permissive=0

Bug: 186872139
Signed-off-by: Jenny Ho <hsiufangho@google.com>
Change-Id: Id8868d2b12408d4a39ba42c8b0faf801923f73f3
This commit is contained in:
Jenny Ho 2021-05-04 15:24:38 +08:00
parent 48e3555770
commit f5b47095be
2 changed files with 2 additions and 0 deletions

View file

@ -9,6 +9,7 @@ genfscon sysfs /wifi u:ob
# Battery # Battery
genfscon sysfs /devices/platform/google,battery/power_supply/battery u:object_r:sysfs_batteryinfo:s0 genfscon sysfs /devices/platform/google,battery/power_supply/battery u:object_r:sysfs_batteryinfo:s0
genfscon sysfs /devices/platform/google,cpm/power_supply u:object_r:sysfs_batteryinfo:s0 genfscon sysfs /devices/platform/google,cpm/power_supply u:object_r:sysfs_batteryinfo:s0
genfscon sysfs /devices/platform/google,charger u:object_r:sysfs_batteryinfo:s0
# Slider # Slider
genfscon sysfs /devices/platform/10d50000.hsi2c/i2c-8/8-0050 u:object_r:sysfs_batteryinfo:s0 genfscon sysfs /devices/platform/10d50000.hsi2c/i2c-8/8-0050 u:object_r:sysfs_batteryinfo:s0

View file

@ -66,6 +66,7 @@ allow hal_dumpstate_default proc_f2fs:file r_file_perms;
allow hal_dumpstate_default proc_touch:file rw_file_perms; allow hal_dumpstate_default proc_touch:file rw_file_perms;
allow hal_dumpstate_default sysfs_batteryinfo:dir search; allow hal_dumpstate_default sysfs_batteryinfo:dir search;
allow hal_dumpstate_default sysfs_batteryinfo:dir r_dir_perms;
allow hal_dumpstate_default sysfs_batteryinfo:file r_file_perms; allow hal_dumpstate_default sysfs_batteryinfo:file r_file_perms;
allow hal_dumpstate_default sysfs_chip_id:file r_file_perms; allow hal_dumpstate_default sysfs_chip_id:file r_file_perms;