From 40bf4a249dc920856f7451df7374b4d6ba30462e Mon Sep 17 00:00:00 2001 From: Roy Luo Date: Wed, 16 Aug 2023 19:04:51 +0000 Subject: [PATCH] Support monitoring USB sysfs attributes in USB HAL Grant access to USB sysfs attributes. Bug: 285199434 Test: no audit log in logcat after command execution Change-Id: Ic9c61cb5153e06eb9db15f4451a4e6769d688431 --- whitechapel/vendor/google/hal_usb_impl.te | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/whitechapel/vendor/google/hal_usb_impl.te b/whitechapel/vendor/google/hal_usb_impl.te index 97ec1c7c..cd2cbf89 100644 --- a/whitechapel/vendor/google/hal_usb_impl.te +++ b/whitechapel/vendor/google/hal_usb_impl.te @@ -26,3 +26,7 @@ allow hal_usb_impl sysfs_usbc_throttling_stats:file r_file_perms; # For checking contaminant detection status get_prop(hal_usb_impl, vendor_usb_config_prop); + +# For monitoring usb sysfs attributes +allow hal_usb_impl sysfs_wakeup:dir search; +allow hal_usb_impl sysfs_wakeup:file r_file_perms;