bramble-sepolicy: allow dumpstate hal to access proc/bldrlog

am: a685c04218

Change-Id: I047d68ce5d5ec5e7a3086792b14dbc78dd8a2f2a
This commit is contained in:
Jone Chou
2019-08-30 06:23:29 -07:00
committed by android-build-merger
3 changed files with 13 additions and 1 deletions

View File

@@ -37,3 +37,6 @@ type sysfs_contaminant, sysfs_type, fs_type;
type hal_neuralnetworks_darwinn_hal_camera_data_file, file_type, data_file_type;
type camera_calibration_vendor_data_file, file_type, data_file_type;
type sysfs_knowles_info, fs_type, sysfs_type;
# Dumpstates bootloader logs
type proc_bldrlog, fs_type, proc_type;

View File

@@ -160,3 +160,6 @@ genfscon debugfs /pmic-votable u:object_r:debugfs_pmic:s0
# USB contaminant detection
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-02/c440000.qcom,spmi:qcom,pm8150b@2:qcom,qpnp-smb5/power_supply/usb/moisture_detected u:object_r:sysfs_contaminant:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-02/c440000.qcom,spmi:qcom,pm8150b@2:qcom,qpnp-smb5/power_supply/usb/moisture_detection_enabled u:object_r:sysfs_contaminant:s0
# Bootloader
genfscon proc /bldrlog u:object_r:proc_bldrlog:s0

View File

@@ -1,3 +1,9 @@
type hal_dumpstate_impl, domain;
type hal_dumpstate_impl_exec, exec_type, vendor_file_type, file_type;
init_daemon_domain(hal_dumpstate_impl)
init_daemon_domain(hal_dumpstate_impl)
userdebug_or_eng(`
allow hal_dumpstate_impl proc_bldrlog:file r_file_perms;
')
dontaudit hal_dumpstate_impl proc_bldrlog:file r_file_perms;