sepolicy: adding vendor_persist_type attribute.
adding neverallow so that coredomain should not access persist file. Change-Id: If8ab44db78e08e347cb33239bf2544c22c362b5b
This commit is contained in:
parent
90ce94f5b4
commit
f66d6d1c7b
4 changed files with 8 additions and 7 deletions
6
generic/vendor/common/domain.te
vendored
6
generic/vendor/common/domain.te
vendored
|
@ -50,3 +50,9 @@ dontaudit domain kernel:system module_request;
|
|||
# For compliance testing test suite reads vendor_security_path_level
|
||||
# Which is the public readable property “ ro.vendor.build.security_patch
|
||||
get_prop(domain, vendor_security_patch_level_prop)
|
||||
neverallow {
|
||||
coredomain
|
||||
-init
|
||||
-ueventd
|
||||
-vold
|
||||
} vendor_persist_type: { dir file } *;
|
||||
|
|
3
generic/vendor/common/file.te
vendored
3
generic/vendor/common/file.te
vendored
|
@ -108,7 +108,8 @@ type location_data_file, file_type, data_file_type;
|
|||
type vendor_audio_data_file, file_type, data_file_type;
|
||||
type vendor_radio_data_file, file_type, data_file_type;
|
||||
type wifi_vendor_log_data_file, file_type, data_file_type;
|
||||
|
||||
# for mount /persist
|
||||
typeattribute mnt_vendor_file vendor_persist_type;
|
||||
type persist_file, file_type, vendor_persist_type;
|
||||
type persist_data_file, file_type , vendor_persist_type;
|
||||
type persist_display_file, file_type;
|
||||
|
|
2
generic/vendor/common/kernel.te
vendored
2
generic/vendor/common/kernel.te
vendored
|
@ -40,5 +40,3 @@ r_dir_file(kernel, firmware_file)
|
|||
r_dir_file(kernel, vendor_firmware_file)
|
||||
|
||||
dontaudit kernel kernel:system module_request;
|
||||
|
||||
allow kernel persist_file:dir search;
|
||||
|
|
4
generic/vendor/common/system_server.te
vendored
4
generic/vendor/common/system_server.te
vendored
|
@ -33,10 +33,6 @@ binder_call(system_server, hal_graphics_composer)
|
|||
|
||||
# location
|
||||
binder_call(system_server, location);
|
||||
|
||||
allow system_server persist_file:dir search;
|
||||
allow system_server persist_sensors_file:dir search;
|
||||
allow system_server persist_sensors_file:file r_file_perms;
|
||||
allow system_server wlan_device:chr_file rw_file_perms;
|
||||
allow system_server hal_audio_default:file w_file_perms;
|
||||
|
||||
|
|
Loading…
Reference in a new issue