|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
141cff |
policy_module(uwimap,1.0.1)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
########################################
|
|
Chris PeBenito |
3eec24 |
#
|
|
Chris PeBenito |
3eec24 |
# Declarations
|
|
Chris PeBenito |
3eec24 |
#
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
type imapd_t;
|
|
Chris PeBenito |
3eec24 |
type imapd_exec_t;
|
|
Chris PeBenito |
3eec24 |
init_daemon_domain(imapd_t,imapd_exec_t)
|
|
Chris PeBenito |
3eec24 |
inetd_tcp_service_domain(imapd_t,imapd_exec_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
type imapd_tmp_t;
|
|
Chris PeBenito |
3eec24 |
files_tmp_file(imapd_tmp_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
type imapd_var_run_t;
|
|
Chris PeBenito |
3eec24 |
files_pid_file(imapd_var_run_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
########################################
|
|
Chris PeBenito |
3eec24 |
#
|
|
Chris PeBenito |
3eec24 |
# Local policy
|
|
Chris PeBenito |
3eec24 |
#
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
allow imapd_t self:capability { dac_override net_bind_service setgid setuid sys_resource };
|
|
Chris PeBenito |
3eec24 |
dontaudit imapd_t self:capability sys_tty_config;
|
|
Chris PeBenito |
3eec24 |
allow imapd_t self:process signal_perms;
|
|
Chris PeBenito |
3eec24 |
allow imapd_t self:fifo_file rw_file_perms;
|
|
Chris PeBenito |
3eec24 |
allow imapd_t self:tcp_socket create_stream_socket_perms;
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
allow imapd_t imapd_tmp_t:dir create_dir_perms;
|
|
Chris PeBenito |
3eec24 |
allow imapd_t imapd_tmp_t:file create_file_perms;
|
|
Chris PeBenito |
3eec24 |
files_tmp_filetrans(imapd_t, imapd_tmp_t, { file dir })
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
allow imapd_t imapd_var_run_t:file create_file_perms;
|
|
Chris PeBenito |
3eec24 |
allow imapd_t imapd_var_run_t:dir rw_dir_perms;
|
|
Chris PeBenito |
3eec24 |
files_pid_filetrans(imapd_t,imapd_var_run_t,file)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
kernel_read_kernel_sysctls(imapd_t)
|
|
Chris PeBenito |
3eec24 |
kernel_list_proc(imapd_t)
|
|
Chris PeBenito |
3eec24 |
kernel_read_proc_symlinks(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
corenet_non_ipsec_sendrecv(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_sendrecv_generic_if(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_sendrecv_all_nodes(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_sendrecv_all_ports(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_bind_all_nodes(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_bind_pop_port(imapd_t)
|
|
Chris PeBenito |
3eec24 |
corenet_tcp_connect_all_ports(imapd_t)
|
|
Chris PeBenito |
141cff |
corenet_sendrecv_pop_server_packets(imapd_t)
|
|
Chris PeBenito |
141cff |
corenet_sendrecv_all_client_packets(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
dev_read_sysfs(imapd_t)
|
|
Chris PeBenito |
3eec24 |
#urandom, for ssl
|
|
Chris PeBenito |
3eec24 |
dev_read_rand(imapd_t)
|
|
Chris PeBenito |
3eec24 |
dev_read_urand(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
domain_use_interactive_fds(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
#read /etc/ for hostname nsswitch.conf
|
|
Chris PeBenito |
3eec24 |
files_read_etc_files(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
fs_getattr_all_fs(imapd_t)
|
|
Chris PeBenito |
3eec24 |
fs_search_auto_mountpoints(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
term_dontaudit_use_console(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
auth_domtrans_chk_passwd(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
init_use_fds(imapd_t)
|
|
Chris PeBenito |
3eec24 |
init_use_script_ptys(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
libs_use_ld_so(imapd_t)
|
|
Chris PeBenito |
3eec24 |
libs_use_shared_libs(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
logging_send_syslog_msg(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
miscfiles_read_localization(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
sysnet_read_config(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
userdom_dontaudit_use_unpriv_user_fds(imapd_t)
|
|
Chris PeBenito |
3eec24 |
userdom_dontaudit_search_sysadm_home_dirs(imapd_t)
|
|
Chris PeBenito |
3eec24 |
# cjp: this is excessive, should be limited to the
|
|
Chris PeBenito |
3eec24 |
# mail directories
|
|
Chris PeBenito |
3eec24 |
userdom_priveleged_home_dir_manager(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
mta_rw_spool(imapd_t)
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
ifdef(`targeted_policy',`
|
|
Chris PeBenito |
3eec24 |
term_dontaudit_use_unallocated_ttys(imapd_t)
|
|
Chris PeBenito |
3eec24 |
term_dontaudit_use_generic_ptys(imapd_t)
|
|
Chris PeBenito |
3eec24 |
files_dontaudit_read_root_files(imapd_t)
|
|
Chris PeBenito |
3eec24 |
')
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
optional_policy(`
|
|
Chris PeBenito |
3eec24 |
seutil_sigchld_newrole(imapd_t)
|
|
Chris PeBenito |
3eec24 |
')
|
|
Chris PeBenito |
3eec24 |
|
|
Chris PeBenito |
3eec24 |
optional_policy(`
|
|
Chris PeBenito |
3eec24 |
udev_read_db(imapd_t)
|
|
Chris PeBenito |
3eec24 |
')
|