Merge "selinux rules for apk files installed with Incremental" am: fcbfe3155f

Change-Id: I179b22c05e431d922871f44ea4f2272024bbd1a4
This commit is contained in:
Automerger Merge Worker 2020-02-11 21:33:49 +00:00
commit a0c022882c
3 changed files with 12 additions and 2 deletions

View file

@ -69,6 +69,9 @@ allow system_app anr_data_file:file create_file_perms;
# Settings need to access app name and icon from asec
allow system_app asec_apk_file:file r_file_perms;
# Allow system_app (adb data loader) to write data to /data/incremental
allow system_app apk_data_file:file write;
# Allow system apps (like Settings) to interact with statsd
binder_call(system_app, statsd)

View file

@ -464,10 +464,10 @@ neverallow appdomain system_data_file:dir_file_class_set
# Write to various other parts of /data.
neverallow appdomain drm_data_file:dir_file_class_set
{ create write setattr relabelfrom relabelto append unlink link rename };
neverallow { appdomain -platform_app }
neverallow { appdomain -platform_app -system_app }
apk_data_file:dir_file_class_set
{ create write setattr relabelfrom relabelto append unlink link rename };
neverallow { appdomain -platform_app }
neverallow { appdomain -platform_app -system_app }
apk_tmp_file:dir_file_class_set
{ create write setattr relabelfrom relabelto append unlink link rename };
neverallow { appdomain -platform_app }

View file

@ -126,6 +126,13 @@ allow vold mnt_expand_file:dir { create_dir_perms mounton };
allow vold apk_data_file:dir { create getattr setattr };
allow vold shell_data_file:dir { create getattr setattr };
# Allow to mount incremental file system on /data/incremental and create files
allow vold apk_data_file:dir { mounton rw_dir_perms };
# Allow to create and write files in /data/incremental
allow vold apk_data_file:file rw_file_perms;
# Allow to bind-mount incremental file system on /data/app/vmdl*.tmp and read files
allow vold apk_tmp_file:dir { mounton r_dir_perms };
allow vold tmpfs:filesystem { mount unmount };
allow vold tmpfs:dir create_dir_perms;
allow vold tmpfs:dir mounton;