Commit graph

9 commits

Author SHA1 Message Date
Adam Shih
de2696eb72 enforce debugfs constraint on userdebug build
Bug: 225815474
Test: build pass
Change-Id: If9e32d4b67c342b56eea39701518a520a62df199
2022-03-24 01:05:18 +00:00
Denny cy Lee
38c2803c54 Sepolicy: add pixelstats/HardwareInfo sepolicy
avc denials to fix (after apply ag/17120763)
[   50.171564] type=1400 audit(1647222380.884:28): avc: denied { read } for comm="pixelstats-vend" name="battery_history" dev="tmpfs" ino=639 scontext=u:r:pixelstats_vendor:s0 tcontext=u:object_r:device:s0 tclass=chr_file permissive=0
[   54.519375] type=1400 audit(1647222385.228:29): avc: denied { read } for comm="id.hardwareinfo" name="battery_history" dev="tmpfs" ino=639 scontext=u:r:hardware_info_app:s0:c512,c768 tcontext=u:object_r:device:s0 tclass=chr_file permissive=0 app=com.google.android.hardwareinfo

Bug: 222019890
Test: manually check debug logcat
Change-Id: I0e4f3f3a66783383b0d1327cec4dcd145ae9a7af
2022-03-15 03:09:18 +00:00
Denny cy Lee
efbd9fa0b2 sepolicy: hwinfo: Add battery fuel gauge permission
Bug: 208909060
Bug: 219660742
Bug: 219660741
Test: check dmeg and search "avc: denied { search } for
comm="id.hardwareinfo" vendor_maxfg_debugfs avc gone after apply patch

Change-Id: I3399e696b59218e62c4d1adcc2a12f5d6ee5c8cc
Signed-off-by: Denny cy Lee <dennycylee@google.com>
2022-02-17 09:04:23 +00:00
Denny cy Lee
92d0030e6a hardwareinfo: add sepolicy for SoC
Bug: 208721710
Test: search avc in logcat

Change-Id: I3828d39981666db98e6a34aa70ae39b7f126e495
Signed-off-by: Denny cy Lee <dennycylee@google.com>
2022-02-08 03:33:06 +00:00
Chris Lu
ca13b6a9bf hardwareinfo: add sepolicy for display
Bug: 203593024
Test: 1. rm -r /data/data/com.google.android.hardwareinfo/
      2. Connect wifi and reboot
      3. Check hardwareinfo, there is no avc denied logs
Change-Id: I44db881286946a283f320302efd6e662fcdae683
2022-01-19 04:27:22 +00:00
Ted Lin
66f8039b5d HardwareInfo: Add sepolicy for battery
12-03 09:57:39.480  7907  7907 I id.hardwareinfo: type=1400 audit(0.0:11): avc: denied { getattr } for path="/sys/devices/platform/google,battery/power_supply/battery/serial_number" dev="sysfs" ino=66176 scontext=u:r:hardware_info_app:s0:c512,c768 tcontext=u:object_r:sysfs_batteryinfo:s0 tclass=file permissive=1
12-03 09:57:39.480  7907  7907 I id.hardwareinfo: type=1400 audit(0.0:10): avc: denied { open } for path="/sys/devices/platform/google,battery/power_supply/battery/serial_number" dev="sysfs" ino=66176 scontext=u:r:hardware_info_app:s0:c512,c768 tcontext=u:object_r:sysfs_batteryinfo:s0 tclass=file permissive=1
12-03 09:57:39.480  7907  7907 I id.hardwareinfo: type=1400 audit(0.0:9): avc: denied { read } for name="serial_number" dev="sysfs" ino=66176 scontext=u:r:hardware_info_app:s0:c512,c768 tcontext=u:object_r:sysfs_batteryinfo:s0 tclass=file permissive=1

Bug:208909060
Test: adb bugreport
Change-Id: Ide376401ada800718acf35db11ce79a5e63fe75d
Signed-off-by: Ted Lin <tedlin@google.com>
2021-12-30 05:21:23 +00:00
Roger Fang
e25c4dca39 sepolicy: add permission for the hardware info putDsp function
Bug: 202814070
Test: Manually test passed

Signed-off-by: Roger Fang <rogerfang@google.com>
Change-Id: I15b8fa09fddc89dcbe7893ef73fea72ac6ae63e4
2021-12-02 04:51:17 +00:00
Randall Huang
a578c846fa storage: update sepolicy for storage suez
Bug: 206741894
Bug: 188793183
Test: boot to home
Signed-off-by: Randall Huang <huangrandall@google.com>
Change-Id: I206178e34156f0b02c4a5b743ac9467e7dafb74f
2021-11-19 17:45:48 +08:00
Adam Shih
1aaa9d5be9 review hardware_info_app
Bug: 196916111
Test: boot with app correctly labeled
Change-Id: I31335fff6356edeedc10ebd2e55b8ed62e39ee02
2021-10-08 11:39:38 +08:00