selinux-refpolicy/refpolicy/policy/modules/admin/tmpreaper.te

54 lines
1.1 KiB
Plaintext

policy_module(tmpreaper,1.2.0)
########################################
#
# Declarations
#
type tmpreaper_t;
role system_r types tmpreaper_t;
domain_type(tmpreaper_t)
type tmpreaper_exec_t;
domain_entry_file(tmpreaper_t,tmpreaper_exec_t)
########################################
#
# Local Policy
#
allow tmpreaper_t self:process { fork sigchld };
allow tmpreaper_t self:capability { dac_override dac_read_search fowner };
dev_read_urand(tmpreaper_t)
fs_getattr_xattr_fs(tmpreaper_t)
files_read_etc_files(tmpreaper_t)
files_read_var_lib_files(tmpreaper_t)
files_purge_tmp(tmpreaper_t)
# why does it need setattr?
files_setattr_all_tmp_dirs(tmpreaper_t)
mls_file_read_up(tmpreaper_t)
mls_file_write_down(tmpreaper_t)
libs_use_ld_so(tmpreaper_t)
libs_use_shared_libs(tmpreaper_t)
logging_send_syslog_msg(tmpreaper_t)
miscfiles_read_localization(tmpreaper_t)
miscfiles_delete_man_pages(tmpreaper_t)
cron_system_entry(tmpreaper_t,tmpreaper_exec_t)
optional_policy(`
lpd_manage_spool(tmpreaper_t)
')
ifdef(`TODO',`
allow tmpreaper_t { home_type file_t }:notdevfile_class_set { getattr unlink };
')