selinux-policy/policy/modules/admin/backup.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

87 lines
2.0 KiB
Plaintext

policy_module(backup,1.1.1)
########################################
#
# Declarations
#
type backup_t;
type backup_exec_t;
domain_type(backup_t)
domain_entry_file(backup_t,backup_exec_t)
role system_r types backup_t;
type backup_store_t;
files_type(backup_store_t)
########################################
#
# Local policy
#
allow backup_t self:capability dac_override;
allow backup_t self:process signal;
allow backup_t self:fifo_file rw_fifo_file_perms;
allow backup_t self:tcp_socket create_socket_perms;
allow backup_t self:udp_socket create_socket_perms;
allow backup_t backup_store_t:file setattr;
create_files_pattern(backup_t,backup_store_t,backup_store_t)
rw_files_pattern(backup_t,backup_store_t,backup_store_t)
read_lnk_files_pattern(backup_t,backup_store_t,backup_store_t)
kernel_read_system_state(backup_t)
kernel_read_kernel_sysctls(backup_t)
corecmd_exec_bin(backup_t)
corenet_all_recvfrom_unlabeled(backup_t)
corenet_all_recvfrom_netlabel(backup_t)
corenet_tcp_sendrecv_generic_if(backup_t)
corenet_udp_sendrecv_generic_if(backup_t)
corenet_raw_sendrecv_generic_if(backup_t)
corenet_tcp_sendrecv_all_nodes(backup_t)
corenet_udp_sendrecv_all_nodes(backup_t)
corenet_raw_sendrecv_all_nodes(backup_t)
corenet_tcp_sendrecv_all_ports(backup_t)
corenet_udp_sendrecv_all_ports(backup_t)
corenet_tcp_connect_all_ports(backup_t)
corenet_sendrecv_all_client_packets(backup_t)
dev_getattr_all_blk_files(backup_t)
dev_getattr_all_chr_files(backup_t)
# for SSP
dev_read_urand(backup_t)
domain_use_interactive_fds(backup_t)
files_read_all_files(backup_t)
files_read_all_symlinks(backup_t)
files_getattr_all_pipes(backup_t)
files_getattr_all_sockets(backup_t)
fs_getattr_xattr_fs(backup_t)
fs_list_all(backup_t)
auth_read_shadow(backup_t)
libs_use_ld_so(backup_t)
libs_use_shared_libs(backup_t)
logging_send_syslog_msg(backup_t)
sysnet_read_config(backup_t)
optional_policy(`
cron_system_entry(backup_t,backup_exec_t)
')
optional_policy(`
hostname_exec(backup_t)
')
optional_policy(`
nis_use_ypbind(backup_t)
')