Chris PeBenito 0fbfa5
#DESC arpwatch -  keep track of ethernet/ip address pairings
Chris PeBenito 0fbfa5
#
Chris PeBenito 0fbfa5
# Author:  Dan Walsh <dwalsh@redhat.com>
Chris PeBenito 0fbfa5
#
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
#################################
Chris PeBenito 0fbfa5
#
Chris PeBenito 0fbfa5
# Rules for the arpwatch_t domain.
Chris PeBenito 0fbfa5
#
Chris PeBenito 0fbfa5
# arpwatch_exec_t is the type of the arpwatch executable.
Chris PeBenito 0fbfa5
#
Chris PeBenito 0fbfa5
daemon_domain(arpwatch, `, privmail')
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
# for files created by arpwatch
Chris PeBenito 0fbfa5
type arpwatch_data_t, file_type, sysadmfile;
Chris PeBenito 0fbfa5
create_dir_file(arpwatch_t,arpwatch_data_t)
Chris PeBenito 0fbfa5
tmp_domain(arpwatch)
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
allow arpwatch_t self:capability { net_admin net_raw setgid setuid };
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
can_network_server(arpwatch_t)
Chris PeBenito 0fbfa5
allow arpwatch_t self:netlink_route_socket r_netlink_socket_perms;
Chris PeBenito 0fbfa5
allow arpwatch_t self:udp_socket create_socket_perms;
Chris PeBenito 0fbfa5
allow arpwatch_t self:unix_dgram_socket create_socket_perms;
Chris PeBenito 0fbfa5
allow arpwatch_t self:packet_socket create_socket_perms;
Chris PeBenito 0fbfa5
allow arpwatch_t self:unix_stream_socket create_stream_socket_perms;
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
allow arpwatch_t { sbin_t var_lib_t }:dir search;
Chris PeBenito 0fbfa5
allow arpwatch_t sbin_t:lnk_file read;
Chris PeBenito 0fbfa5
r_dir_file(arpwatch_t, etc_t)
Chris PeBenito 0fbfa5
r_dir_file(arpwatch_t, usr_t)
Chris PeBenito 0fbfa5
can_ypbind(arpwatch_t)
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
ifdef(`qmail.te', `
Chris PeBenito 0fbfa5
allow arpwatch_t bin_t:dir search;
Chris PeBenito 0fbfa5
')
Chris PeBenito 0fbfa5
Chris PeBenito 0fbfa5
ifdef(`distro_gentoo', `
Chris PeBenito 0fbfa5
allow initrc_t arpwatch_data_t:dir { add_name write };
Chris PeBenito 0fbfa5
allow initrc_t arpwatch_data_t:file create;
Chris PeBenito 0fbfa5
')dnl end distro_gentoo
Chris PeBenito 0fbfa5