2006-04-26 18:18:15 +00:00
|
|
|
|
2008-04-29 13:58:34 +00:00
|
|
|
policy_module(vmware,1.5.1)
|
2006-04-26 18:18:15 +00:00
|
|
|
|
|
|
|
########################################
|
|
|
|
#
|
|
|
|
# Declarations
|
|
|
|
#
|
|
|
|
|
|
|
|
# VMWare user program
|
|
|
|
type vmware_exec_t;
|
|
|
|
corecmd_executable_file(vmware_exec_t)
|
|
|
|
|
|
|
|
# VMWare host programs
|
|
|
|
type vmware_host_t;
|
|
|
|
type vmware_host_exec_t;
|
|
|
|
init_daemon_domain(vmware_host_t,vmware_host_exec_t)
|
|
|
|
|
|
|
|
# Systemwide configuration files
|
|
|
|
type vmware_sys_conf_t;
|
|
|
|
files_type(vmware_sys_conf_t)
|
|
|
|
|
|
|
|
type vmware_var_run_t;
|
|
|
|
files_pid_file(vmware_var_run_t)
|
|
|
|
|
|
|
|
########################################
|
|
|
|
#
|
|
|
|
# VMWare host local policy
|
|
|
|
#
|
|
|
|
|
2006-04-26 19:03:41 +00:00
|
|
|
allow vmware_host_t self:capability { setuid net_raw };
|
2006-04-26 18:18:15 +00:00
|
|
|
dontaudit vmware_host_t self:capability sys_tty_config;
|
|
|
|
allow vmware_host_t self:process signal_perms;
|
2006-12-12 20:08:08 +00:00
|
|
|
allow vmware_host_t self:fifo_file rw_fifo_file_perms;
|
2006-04-26 19:03:41 +00:00
|
|
|
allow vmware_host_t self:unix_stream_socket create_stream_socket_perms;
|
|
|
|
allow vmware_host_t self:rawip_socket create_socket_perms;
|
2006-04-26 18:18:15 +00:00
|
|
|
|
2006-04-26 19:03:41 +00:00
|
|
|
# cjp: the ro and rw files should be split up
|
2006-12-12 20:08:08 +00:00
|
|
|
manage_files_pattern(vmware_host_t,vmware_sys_conf_t,vmware_sys_conf_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
|
2006-12-12 20:08:08 +00:00
|
|
|
manage_files_pattern(vmware_host_t,vmware_var_run_t,vmware_var_run_t)
|
|
|
|
manage_sock_files_pattern(vmware_host_t,vmware_var_run_t,vmware_var_run_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
files_pid_filetrans(vmware_host_t,vmware_var_run_t,{ file sock_file })
|
2006-04-26 18:18:15 +00:00
|
|
|
|
|
|
|
kernel_read_kernel_sysctls(vmware_host_t)
|
|
|
|
kernel_list_proc(vmware_host_t)
|
|
|
|
kernel_read_proc_symlinks(vmware_host_t)
|
|
|
|
|
2007-06-27 15:23:21 +00:00
|
|
|
corenet_all_recvfrom_unlabeled(vmware_host_t)
|
|
|
|
corenet_all_recvfrom_netlabel(vmware_host_t)
|
2006-06-01 18:17:53 +00:00
|
|
|
corenet_tcp_sendrecv_generic_if(vmware_host_t)
|
|
|
|
corenet_udp_sendrecv_generic_if(vmware_host_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
corenet_raw_sendrecv_generic_if(vmware_host_t)
|
2006-06-01 18:17:53 +00:00
|
|
|
corenet_tcp_sendrecv_all_nodes(vmware_host_t)
|
|
|
|
corenet_udp_sendrecv_all_nodes(vmware_host_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
corenet_raw_sendrecv_all_nodes(vmware_host_t)
|
2006-05-29 18:25:58 +00:00
|
|
|
corenet_tcp_sendrecv_all_ports(vmware_host_t)
|
2006-06-01 18:17:53 +00:00
|
|
|
corenet_udp_sendrecv_all_ports(vmware_host_t)
|
|
|
|
corenet_raw_bind_all_nodes(vmware_host_t)
|
2007-08-22 20:02:41 +00:00
|
|
|
corenet_tcp_bind_all_nodes(vmware_host_t)
|
|
|
|
corenet_udp_bind_all_nodes(vmware_host_t)
|
2006-05-29 18:25:58 +00:00
|
|
|
corenet_tcp_connect_all_ports(vmware_host_t)
|
|
|
|
corenet_sendrecv_all_client_packets(vmware_host_t)
|
2006-06-01 18:17:53 +00:00
|
|
|
corenet_sendrecv_all_server_packets(vmware_host_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
|
2006-04-26 18:18:15 +00:00
|
|
|
dev_read_sysfs(vmware_host_t)
|
2006-04-26 19:03:41 +00:00
|
|
|
dev_rw_vmware(vmware_host_t)
|
2006-04-26 18:18:15 +00:00
|
|
|
|
|
|
|
domain_use_interactive_fds(vmware_host_t)
|
|
|
|
|
2006-04-26 19:03:41 +00:00
|
|
|
files_read_etc_files(vmware_host_t)
|
|
|
|
|
2006-04-26 18:18:15 +00:00
|
|
|
fs_getattr_all_fs(vmware_host_t)
|
|
|
|
fs_search_auto_mountpoints(vmware_host_t)
|
|
|
|
|
|
|
|
term_dontaudit_use_console(vmware_host_t)
|
|
|
|
|
|
|
|
init_use_fds(vmware_host_t)
|
|
|
|
init_use_script_ptys(vmware_host_t)
|
|
|
|
|
|
|
|
libs_use_ld_so(vmware_host_t)
|
|
|
|
libs_use_shared_libs(vmware_host_t)
|
|
|
|
|
|
|
|
logging_send_syslog_msg(vmware_host_t)
|
|
|
|
|
|
|
|
miscfiles_read_localization(vmware_host_t)
|
|
|
|
|
2006-05-09 20:13:25 +00:00
|
|
|
sysnet_dns_name_resolve(vmware_host_t)
|
|
|
|
|
2006-04-26 18:18:15 +00:00
|
|
|
userdom_dontaudit_use_unpriv_user_fds(vmware_host_t)
|
2008-04-29 13:58:34 +00:00
|
|
|
|
|
|
|
sysadm_dontaudit_search_home_dirs(vmware_host_t)
|
2006-04-26 18:18:15 +00:00
|
|
|
|
|
|
|
optional_policy(`
|
|
|
|
seutil_sigchld_newrole(vmware_host_t)
|
|
|
|
|
|
|
|
')
|
|
|
|
|
|
|
|
optional_policy(`
|
|
|
|
udev_read_db(vmware_host_t)
|
|
|
|
')
|
2006-04-26 19:03:41 +00:00
|
|
|
netutils_domtrans_ping(vmware_host_t)
|
2006-04-26 18:18:15 +00:00
|
|
|
|
|
|
|
ifdef(`TODO',`
|
|
|
|
# VMWare need access to pcmcia devices for network
|
|
|
|
optional_policy(`
|
|
|
|
allow kernel_t cardmgr_var_lib_t:dir { getattr search };
|
|
|
|
allow kernel_t cardmgr_var_lib_t:file { getattr ioctl read };
|
|
|
|
')
|
|
|
|
# Vmware create network devices
|
|
|
|
allow kernel_t self:capability net_admin;
|
|
|
|
allow kernel_t self:netlink_route_socket { bind create getattr nlmsg_read nlmsg_write read write };
|
|
|
|
allow kernel_t self:socket create;
|
|
|
|
')
|