selinux-policy/policy/modules/services/rwho.te
Chris PeBenito 1900668638 trunk: Unified labeled networking policy from Paul Moore.
The latest revision of the labeled policy patches which enable both labeled 
and unlabeled policy support for NetLabel.  This revision takes into account
Chris' feedback from the first version and reduces the number of interface
calls in each domain down to two at present: one for unlabeled access, one for
NetLabel access.  The older, transport layer specific interfaces, are still  
present for use by third-party modules but are not used in the default policy
modules.

trunk: Use netmsg initial SID for MLS-only Netlabel packets, from Paul Moore.

This patch changes the policy to use the netmsg initial SID as the "base"
SID/context for NetLabel packets which only have MLS security attributes.
Currently we use the unlabeled initial SID which makes it very difficult to
distinquish between actual unlabeled packets and those packets which have MLS
security attributes.
2007-06-27 15:23:21 +00:00

62 lines
1.4 KiB
Plaintext

policy_module(rwho,1.0.2)
########################################
#
# Declarations
#
type rwho_t;
type rwho_exec_t;
init_daemon_domain(rwho_t, rwho_exec_t)
# var/spool files
type rwho_spool_t;
files_type(rwho_spool_t)
########################################
#
# rwho local policy
#
allow rwho_t self:capability sys_chroot;
allow rwho_t self:unix_dgram_socket create;
allow rwho_t self:fifo_file rw_file_perms;
allow rwho_t self:unix_stream_socket create_stream_socket_perms;
allow rwho_t self:udp_socket create_socket_perms;
# var/spool files for rwho
allow rwho_t rwho_spool_t:dir manage_dir_perms;
allow rwho_t rwho_spool_t:file manage_file_perms;
files_spool_filetrans(rwho_t,rwho_spool_t, { file dir })
kernel_read_system_state(rwho_t)
corenet_all_recvfrom_unlabeled(rwho_t)
corenet_all_recvfrom_netlabel(rwho_t)
corenet_udp_sendrecv_all_if(rwho_t)
corenet_udp_sendrecv_all_nodes(rwho_t)
corenet_udp_sendrecv_all_ports(rwho_t)
corenet_udp_bind_all_nodes(rwho_t)
corenet_udp_bind_rwho_port(rwho_t)
corenet_sendrecv_rwho_server_packets(rwho_t)
domain_use_interactive_fds(rwho_t)
files_read_etc_files(rwho_t)
init_read_utmp(rwho_t)
init_dontaudit_write_utmp(rwho_t)
libs_use_ld_so(rwho_t)
libs_use_shared_libs(rwho_t)
miscfiles_read_localization(rwho_t)
sysnet_dns_name_resolve(rwho_t)
ifdef(`targeted_policy',`
term_dontaudit_use_unallocated_ttys(rwho_t)
term_dontaudit_use_generic_ptys(rwho_t)
')