Chris PeBenito 3f4188
Chris PeBenito 87eb5c
policy_module(xfs,1.0.2)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
########################################
Chris PeBenito 3f4188
#
Chris PeBenito 3f4188
# Declarations
Chris PeBenito 3f4188
#
Chris PeBenito 3f4188
Chris PeBenito 3f4188
type xfs_t;
Chris PeBenito 3f4188
type xfs_exec_t;
Chris PeBenito 3f4188
init_daemon_domain(xfs_t,xfs_exec_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
type xfs_tmp_t;
Chris PeBenito 3f4188
files_tmp_file(xfs_tmp_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
type xfs_var_run_t;
Chris PeBenito 3f4188
files_pid_file(xfs_var_run_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
########################################
Chris PeBenito 3f4188
#
Chris PeBenito 3f4188
# Local policy
Chris PeBenito 3f4188
#
Chris PeBenito 3f4188
Chris PeBenito 3f4188
allow xfs_t self:capability { setgid setuid };
Chris PeBenito 3f4188
dontaudit xfs_t self:capability sys_tty_config;
Chris PeBenito 3f4188
allow xfs_t self:process { signal_perms setpgid };
Chris PeBenito 3f4188
allow xfs_t self:unix_stream_socket create_stream_socket_perms;
Chris PeBenito 3f4188
allow xfs_t self:unix_dgram_socket create_socket_perms;
Chris PeBenito 3f4188
Chris PeBenito 3f4188
allow xfs_t xfs_tmp_t:dir create_dir_perms;
Chris PeBenito 3f4188
allow xfs_t xfs_tmp_t:sock_file create_file_perms;
Chris PeBenito 103fe2
files_tmp_filetrans(xfs_t, xfs_tmp_t, { sock_file dir })
Chris PeBenito 3f4188
Chris PeBenito 3f4188
allow xfs_t xfs_var_run_t:file create_file_perms;
Chris PeBenito 3f4188
allow xfs_t xfs_var_run_t:dir rw_dir_perms;
Chris PeBenito 1c1ac6
files_pid_filetrans(xfs_t,xfs_var_run_t,file)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
# Bind to /tmp/.font-unix/fs-1.
Chris PeBenito 3f4188
# cjp: I do not believe this has an effect.
Chris PeBenito 3f4188
allow xfs_t xfs_tmp_t:unix_stream_socket name_bind;
Chris PeBenito 3f4188
Chris PeBenito 445522
kernel_read_kernel_sysctls(xfs_t)
Chris PeBenito 3f4188
kernel_read_system_state(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 87eb5c
corecmd_list_bin(xfs_t)
Chris PeBenito 87eb5c
corecmd_list_sbin(xfs_t)
Chris PeBenito 87eb5c
Chris PeBenito 3f4188
dev_read_sysfs(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
fs_getattr_all_fs(xfs_t)
Chris PeBenito 3f4188
fs_search_auto_mountpoints(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 15722e
domain_use_interactive_fds(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
files_read_etc_files(xfs_t)
Chris PeBenito 3f4188
files_read_etc_runtime_files(xfs_t)
Chris PeBenito 724925
files_read_usr_files(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 87eb5c
term_dontaudit_use_console(xfs_t)
Chris PeBenito 87eb5c
Chris PeBenito 1c1ac6
init_use_fds(xfs_t)
Chris PeBenito 1815ba
init_use_script_ptys(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
libs_use_ld_so(xfs_t)
Chris PeBenito 3f4188
libs_use_shared_libs(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
logging_send_syslog_msg(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 3f4188
miscfiles_read_localization(xfs_t)
Chris PeBenito 3f4188
miscfiles_read_fonts(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 15722e
userdom_dontaudit_use_unpriv_user_fds(xfs_t)
Chris PeBenito 103fe2
userdom_dontaudit_search_sysadm_home_dirs(xfs_t)
Chris PeBenito 3f4188
Chris PeBenito 87eb5c
xfs_exec(xfs_t)
Chris PeBenito 87eb5c
Chris PeBenito 3f4188
ifdef(`distro_debian',`
Chris PeBenito 3f4188
	# for /tmp/.font-unix/fs7100
Chris PeBenito 103fe2
	init_script_tmp_filetrans(xfs_t,xfs_tmp_t,sock_file)
Chris PeBenito 3f4188
')
Chris PeBenito 3f4188
Chris PeBenito 3f4188
ifdef(`targeted_policy',`
Chris PeBenito 1815ba
	term_dontaudit_use_unallocated_ttys(xfs_t)
Chris PeBenito 1815ba
	term_dontaudit_use_generic_ptys(xfs_t)
Chris PeBenito 9e04f5
	files_dontaudit_read_root_files(xfs_t)
Chris PeBenito 3f4188
')
Chris PeBenito 3f4188
Chris PeBenito bb7170
optional_policy(`
Chris PeBenito 3f4188
	nis_use_ypbind(xfs_t)
Chris PeBenito 3f4188
')
Chris PeBenito 3f4188
Chris PeBenito bb7170
optional_policy(`
Chris PeBenito 3f4188
	seutil_sigchld_newrole(xfs_t)
Chris PeBenito 3f4188
')
Chris PeBenito 3f4188
Chris PeBenito bb7170
optional_policy(`
Chris PeBenito 3f4188
	udev_read_db(xfs_t)
Chris PeBenito 3f4188
')