Chris PeBenito 902be0
Chris PeBenito 902be0
policy_module(privoxy,1.0)
Chris PeBenito 902be0
Chris PeBenito 902be0
########################################
Chris PeBenito 902be0
#
Chris PeBenito 902be0
# Declarations
Chris PeBenito 902be0
#
Chris PeBenito 902be0
Chris PeBenito 902be0
type privoxy_t;
Chris PeBenito 902be0
type privoxy_exec_t;
Chris PeBenito 902be0
init_daemon_domain(privoxy_t,privoxy_exec_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
type privoxy_log_t;
Chris PeBenito 902be0
logging_log_file(privoxy_log_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
type privoxy_var_run_t;
Chris PeBenito 902be0
files_pid_file(privoxy_var_run_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
########################################
Chris PeBenito 902be0
#
Chris PeBenito 902be0
# Local Policy
Chris PeBenito 902be0
#
Chris PeBenito 902be0
Chris PeBenito 902be0
allow privoxy_t self:capability { setgid setuid };
Chris PeBenito 902be0
dontaudit privoxy_t self:capability sys_tty_config;
Chris PeBenito 902be0
Chris PeBenito 902be0
allow privoxy_t privoxy_log_t:file create_file_perms;
Chris PeBenito 902be0
allow privoxy_t privoxy_log_t:dir rw_dir_perms;
Chris PeBenito 902be0
logging_search_logs(privoxy_t,privoxy_log_t,{ file dir })
Chris PeBenito 902be0
Chris PeBenito 902be0
allow privoxy_t privoxy_var_run_t:file create_file_perms;
Chris PeBenito 902be0
files_create_pid(privoxy_t,privoxy_var_run_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
kernel_read_kernel_sysctl(privoxy_t)
Chris PeBenito 902be0
kernel_list_proc(privoxy_t)
Chris PeBenito 902be0
kernel_read_proc_symlinks(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
corenet_tcp_sendrecv_all_if(privoxy_t)
Chris PeBenito 902be0
corenet_udp_sendrecv_all_if(privoxy_t)
Chris PeBenito 902be0
corenet_raw_sendrecv_all_if(privoxy_t)
Chris PeBenito 902be0
corenet_tcp_sendrecv_all_nodes(privoxy_t)
Chris PeBenito 902be0
corenet_udp_sendrecv_all_nodes(privoxy_t)
Chris PeBenito 902be0
corenet_raw_sendrecv_all_nodes(privoxy_t)
Chris PeBenito 902be0
corenet_tcp_sendrecv_all_ports(privoxy_t)
Chris PeBenito 902be0
corenet_udp_sendrecv_all_ports(privoxy_t)
Chris PeBenito 902be0
# cjp: this really should be specified!
Chris PeBenito 902be0
corenet_tcp_bind_generic_port(privoxy_t)
Chris PeBenito 902be0
corenet_udp_bind_generic_port(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
dev_read_sysfs(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
fs_getattr_all_fs(privoxy_t)
Chris PeBenito 902be0
fs_search_auto_mountpoints(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
term_dontaudit_use_console(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
domain_use_wide_inherit_fd(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
files_read_etc_files(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
init_use_fd(privoxy_t)
Chris PeBenito 902be0
init_use_script_pty(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
libs_use_ld_so(privoxy_t)
Chris PeBenito 902be0
libs_use_shared_libs(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
logging_send_syslog_msg(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
miscfiles_read_localization(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
userdom_dontaudit_use_unpriv_user_fd(privoxy_t)
Chris PeBenito 902be0
userdom_dontaudit_search_sysadm_home_dir(privoxy_t)
Chris PeBenito 902be0
# cjp: this should really not be needed
Chris PeBenito 902be0
userdom_use_sysadm_terms(privoxy_t)
Chris PeBenito 902be0
Chris PeBenito 902be0
ifdef(`targeted_policy',`
Chris PeBenito 902be0
	term_dontaudit_use_unallocated_tty(privoxy_t)
Chris PeBenito 902be0
	term_dontaudit_use_generic_pty(privoxy_t)
Chris PeBenito 902be0
	files_dontaudit_read_root_file(privoxy_t)
Chris PeBenito 902be0
')
Chris PeBenito 902be0
Chris PeBenito 902be0
optional_policy(`mount.te',`
Chris PeBenito 902be0
	mount_send_nfs_client_request(privoxy_t)
Chris PeBenito 902be0
')
Chris PeBenito 902be0
Chris PeBenito 902be0
optional_policy(`selinuxutil.te',`
Chris PeBenito 902be0
	seutil_sigchld_newrole(privoxy_t)
Chris PeBenito 902be0
')
Chris PeBenito 902be0
Chris PeBenito 902be0
optional_policy(`udev.te', `
Chris PeBenito 902be0
	udev_read_db(privoxy_t)
Chris PeBenito 902be0
')
Chris PeBenito c0d156
Chris PeBenito c0d156
ifdef(`TODO',`
Chris PeBenito c0d156
optional_policy(`rhgb.te',`
Chris PeBenito c0d156
	rhgb_domain(privoxy_t)
Chris PeBenito c0d156
')
Chris PeBenito c0d156
')