installd.te 2.38 KB
Newer Older
Stephen Smalley's avatar
Stephen Smalley committed
1 2 3 4 5
# installer daemon
type installd, domain;
type installd_exec, exec_type, file_type;

init_daemon_domain(installd)
6
relabelto_domain(installd)
7 8 9 10 11
typeattribute installd mlstrustedsubject;
allow installd self:capability { chown dac_override fowner fsetid setgid setuid };
allow installd system_data_file:file create_file_perms;
allow installd system_data_file:lnk_file create;
allow installd dalvikcache_data_file:file create_file_perms;
12 13
allow installd dalvikcache_profiles_data_file:dir create_dir_perms;
allow installd dalvikcache_profiles_data_file:file create_file_perms;
14 15
allow installd data_file_type:dir create_dir_perms;
allow installd data_file_type:dir { relabelfrom relabelto };
16
allow installd data_file_type:{ file_class_set } { getattr unlink };
17 18 19 20 21 22 23 24 25 26 27
allow installd apk_data_file:file r_file_perms;
allow installd apk_tmp_file:file r_file_perms;
allow installd system_file:file x_file_perms;
allow installd cgroup:dir create_dir_perms;
# Check validity of SELinux context before use.
selinux_check_context(installd)
# Read /seapp_contexts and /data/security/seapp_contexts
security_access_policy(installd)
# ASEC
allow installd app_data_file:lnk_file { create setattr };
allow installd asec_apk_file:file r_file_perms;
28 29 30 31
allow installd bluetooth_data_file:lnk_file { create setattr };
allow installd nfc_data_file:lnk_file { create setattr };
allow installd radio_data_file:lnk_file { create setattr };
allow installd shell_data_file:lnk_file { create setattr };
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
# restorecon /data/data
allow installd unlabeled:dir relabelfrom;
allow installd unlabeled:notdevfile_class_set relabelfrom;
allow installd system_data_file:dir { relabelfrom relabelto };
allow installd system_data_file:notdevfile_class_set { relabelfrom relabelto };
allow installd bluetooth_data_file:dir { relabelfrom relabelto };
allow installd bluetooth_data_file:notdevfile_class_set { relabelfrom relabelto };
allow installd nfc_data_file:dir { relabelfrom relabelto };
allow installd nfc_data_file:notdevfile_class_set { relabelfrom relabelto };
allow installd radio_data_file:dir { relabelfrom relabelto };
allow installd radio_data_file:notdevfile_class_set { relabelfrom relabelto };
allow installd app_data_file:dir { relabelfrom relabelto };
allow installd app_data_file:notdevfile_class_set { relabelfrom relabelto };
allow installd shell_data_file:dir { relabelfrom relabelto };
allow installd shell_data_file:notdevfile_class_set { relabelfrom relabelto };