[ALPS04709387] Support to catch MCUPM log

Add SELINUX rule for MCUPM log.

MTK-Commit-Id: 9fb8d206f37f0fb00581f4417473974c014ff0dd

Change-Id: I7a935534d4975e444b556d133ff222a4c144b5ca
CR-Id: ALPS04709387
Feature: Mobile Log Tool
This commit is contained in:
hua.tian 2020-01-18 10:17:51 +08:00
parent 103246ae55
commit 608a6fd139
5 changed files with 10 additions and 0 deletions

View File

@ -18,3 +18,5 @@ type access_sys_file, fs_type, sysfs_type;
type mddb_filter_data_file, file_type, data_file_type, core_data_file_type;
type debuglog_data_file, file_type, data_file_type, core_data_file_type;
type sysfs_mcupm, fs_type, sysfs_type;

View File

@ -45,3 +45,4 @@
/dev/ubi[_0-9]* u:object_r:mtd_device:s0
/dev/block/mtd(.*)? u:object_r:mtd_device:s0
/dev/block/mntlblk(.*)? u:object_r:mtd_device:s0
/dev/mcupm(/.*)? u:object_r:mcupm_device:s0

View File

@ -2,3 +2,4 @@
genfscon sysfs /devices/platform/vibrator@0/leds/vibrator u:object_r:sysfs_vibrator:s0
genfscon sysfs /block/mmcblk0rpmb/size u:object_r:access_sys_file:s0
genfscon sysfs /devices/virtual/misc/mcupm u:object_r:sysfs_mcupm:s0

View File

@ -81,3 +81,8 @@ allow mobile_log_d debuglog_data_file:dir {relabelto create_dir_perms};
allow mobile_log_d debuglog_data_file:file create_file_perms;
allow mobile_log_d system_data_file:dir create_dir_perms;
file_type_auto_trans(mobile_log_d, system_data_file, debuglog_data_file)
#mcupm
allow mobile_log_d mcupm_device:chr_file r_file_perms;
allow mobile_log_d sysfs_mcupm:file w_file_perms;
allow mobile_log_d sysfs_mcupm:dir search;

View File

@ -3,3 +3,4 @@
# ==============================================
type mtd_device, dev_type;
type mcupm_device, dev_type;