|
Chris PeBenito |
29af4c |
policy_module(bitlbee, 1.3.0)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
########################################
|
|
Chris PeBenito |
8242f5 |
#
|
|
Chris PeBenito |
8242f5 |
# Declarations
|
|
Chris PeBenito |
8242f5 |
#
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
type bitlbee_t;
|
|
Chris PeBenito |
8242f5 |
type bitlbee_exec_t;
|
|
Chris PeBenito |
8242f5 |
init_daemon_domain(bitlbee_t, bitlbee_exec_t)
|
|
Chris PeBenito |
8242f5 |
inetd_tcp_service_domain(bitlbee_t, bitlbee_exec_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
type bitlbee_conf_t;
|
|
Chris PeBenito |
8242f5 |
files_config_file(bitlbee_conf_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
e87221 |
type bitlbee_initrc_exec_t;
|
|
Chris PeBenito |
e87221 |
init_script_file(bitlbee_initrc_exec_t)
|
|
Chris PeBenito |
e87221 |
|
|
Chris PeBenito |
e87221 |
type bitlbee_tmp_t;
|
|
Chris PeBenito |
e87221 |
files_tmp_file(bitlbee_tmp_t)
|
|
Chris PeBenito |
e87221 |
|
|
Chris PeBenito |
8242f5 |
type bitlbee_var_t;
|
|
Chris PeBenito |
8242f5 |
files_type(bitlbee_var_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
########################################
|
|
Chris PeBenito |
8242f5 |
#
|
|
Chris PeBenito |
8242f5 |
# Local policy
|
|
Chris PeBenito |
8242f5 |
#
|
|
Chris PeBenito |
8242f5 |
#
|
|
Dan Walsh |
3eaa99 |
allow bitlbee_t self:capability { setgid setuid };
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
allow bitlbee_t self:udp_socket create_socket_perms;
|
|
Chris PeBenito |
8242f5 |
allow bitlbee_t self:tcp_socket { create_stream_socket_perms connected_stream_socket_perms };
|
|
Chris PeBenito |
8242f5 |
allow bitlbee_t self:unix_stream_socket create_stream_socket_perms;
|
|
Chris PeBenito |
e87221 |
allow bitlbee_t self:fifo_file rw_fifo_file_perms;
|
|
Chris PeBenito |
e87221 |
allow bitlbee_t self:process signal;
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
bitlbee_read_config(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
e87221 |
# tmp files
|
|
Chris PeBenito |
e87221 |
manage_files_pattern(bitlbee_t, bitlbee_tmp_t, bitlbee_tmp_t)
|
|
Chris PeBenito |
e87221 |
files_tmp_filetrans(bitlbee_t, bitlbee_tmp_t, file)
|
|
Chris PeBenito |
e87221 |
|
|
Chris PeBenito |
8242f5 |
# user account information is read and edited at runtime; give the usual
|
|
Chris PeBenito |
8242f5 |
# r/w access to bitlbee_var_t
|
|
Chris PeBenito |
8242f5 |
manage_files_pattern(bitlbee_t, bitlbee_var_t, bitlbee_var_t)
|
|
Chris PeBenito |
8242f5 |
files_var_lib_filetrans(bitlbee_t, bitlbee_var_t, file)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
20272c |
kernel_read_system_state(bitlbee_t)
|
|
Chris PeBenito |
20272c |
|
|
Chris PeBenito |
8242f5 |
corenet_all_recvfrom_unlabeled(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_udp_sendrecv_generic_if(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_udp_sendrecv_generic_node(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_generic_if(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_generic_node(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
# Allow bitlbee to connect to jabber servers
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_connect_jabber_client_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_jabber_client_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
# to AIM servers:
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_connect_aol_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_aol_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
# and to MMCC (Yahoo IM) servers:
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_connect_mmcc_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_mmcc_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
# and to MSNP (MSN Messenger) servers:
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_connect_msnp_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
corenet_tcp_sendrecv_msnp_port(bitlbee_t)
|
|
Chris PeBenito |
04d286 |
# MSN can use passport auth, which is over http:
|
|
Chris PeBenito |
04d286 |
corenet_tcp_connect_http_port(bitlbee_t)
|
|
Chris PeBenito |
04d286 |
corenet_tcp_sendrecv_http_port(bitlbee_t)
|
|
Chris PeBenito |
a7d606 |
corenet_tcp_connect_http_cache_port(bitlbee_t)
|
|
Chris PeBenito |
a7d606 |
corenet_tcp_sendrecv_http_cache_port(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
e87221 |
dev_read_rand(bitlbee_t)
|
|
Chris PeBenito |
e87221 |
dev_read_urand(bitlbee_t)
|
|
Chris PeBenito |
e87221 |
|
|
Chris PeBenito |
8242f5 |
files_read_etc_files(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
files_search_pids(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
# grant read-only access to the user help files
|
|
Chris PeBenito |
8242f5 |
files_read_usr_files(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
libs_legacy_use_shared_libs(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Dan Walsh |
3eaa99 |
auth_use_nsswitch(bitlbee_t)
|
|
Dan Walsh |
3eaa99 |
|
|
Dan Walsh |
3eaa99 |
logging_send_syslog_msg(bitlbee_t)
|
|
Dan Walsh |
3eaa99 |
|
|
Chris PeBenito |
e87221 |
miscfiles_read_localization(bitlbee_t)
|
|
Chris PeBenito |
e87221 |
|
|
Chris PeBenito |
8242f5 |
sysnet_dns_name_resolve(bitlbee_t)
|
|
Chris PeBenito |
8242f5 |
|
|
Chris PeBenito |
8242f5 |
optional_policy(`
|
|
Chris PeBenito |
8242f5 |
# normally started from inetd using tcpwrappers, so use those entry points
|
|
Chris PeBenito |
8242f5 |
tcpd_wrapped_domain(bitlbee_t, bitlbee_exec_t)
|
|
Chris PeBenito |
8242f5 |
')
|