|
Chris PeBenito |
17de1b |
## <summary>Xen hypervisor</summary>
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Execute a domain transition to run xend.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain allowed to transition.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_domtrans',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type xend_t, xend_exec_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
c0868a |
domtrans_pattern($1,xend_exec_t,xend_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
a5e213 |
########################################
|
|
Chris PeBenito |
a5e213 |
## <summary>
|
|
Chris PeBenito |
a5e213 |
## Inherit and use xen file descriptors.
|
|
Chris PeBenito |
a5e213 |
## </summary>
|
|
Chris PeBenito |
a5e213 |
## <param name="domain">
|
|
Chris PeBenito |
a5e213 |
## <summary>
|
|
Chris PeBenito |
a5e213 |
## Domain to not audit.
|
|
Chris PeBenito |
a5e213 |
## </summary>
|
|
Chris PeBenito |
a5e213 |
## </param>
|
|
Chris PeBenito |
a5e213 |
#
|
|
Chris PeBenito |
a5e213 |
interface(`xen_use_fds',`
|
|
Chris PeBenito |
a5e213 |
gen_require(`
|
|
Chris PeBenito |
a5e213 |
type xend_t;
|
|
Chris PeBenito |
a5e213 |
')
|
|
Chris PeBenito |
a5e213 |
|
|
Chris PeBenito |
a5e213 |
allow $1 xend_t:fd use;
|
|
Chris PeBenito |
a5e213 |
')
|
|
Chris PeBenito |
a5e213 |
|
|
Chris PeBenito |
a5e213 |
########################################
|
|
Chris PeBenito |
a5e213 |
## <summary>
|
|
Chris PeBenito |
a5e213 |
## Do not audit attempts to inherit
|
|
Chris PeBenito |
a5e213 |
## xen file descriptors.
|
|
Chris PeBenito |
a5e213 |
## </summary>
|
|
Chris PeBenito |
a5e213 |
## <param name="domain">
|
|
Chris PeBenito |
a5e213 |
## <summary>
|
|
Chris PeBenito |
a5e213 |
## Domain to not audit.
|
|
Chris PeBenito |
a5e213 |
## </summary>
|
|
Chris PeBenito |
a5e213 |
## </param>
|
|
Chris PeBenito |
a5e213 |
#
|
|
Chris PeBenito |
a5e213 |
interface(`xen_dontaudit_use_fds',`
|
|
Chris PeBenito |
a5e213 |
gen_require(`
|
|
Chris PeBenito |
a5e213 |
type xend_t;
|
|
Chris PeBenito |
a5e213 |
')
|
|
Chris PeBenito |
a5e213 |
|
|
Chris PeBenito |
a5e213 |
dontaudit $1 xend_t:fd use;
|
|
Chris PeBenito |
a5e213 |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
7f0897 |
## Read xend image files.
|
|
Chris PeBenito |
7f0897 |
## </summary>
|
|
Chris PeBenito |
7f0897 |
## <param name="domain">
|
|
Chris PeBenito |
7f0897 |
## <summary>
|
|
Chris PeBenito |
7f0897 |
## Domain allowed access.
|
|
Chris PeBenito |
7f0897 |
## </summary>
|
|
Chris PeBenito |
7f0897 |
## </param>
|
|
Chris PeBenito |
7f0897 |
#
|
|
Chris PeBenito |
7f0897 |
interface(`xen_read_image_files',`
|
|
Chris PeBenito |
7f0897 |
gen_require(`
|
|
Chris PeBenito |
7f0897 |
type xen_image_t, xend_var_lib_t;
|
|
Chris PeBenito |
7f0897 |
')
|
|
Chris PeBenito |
7f0897 |
|
|
Chris PeBenito |
7f0897 |
files_list_var_lib($1)
|
|
Chris PeBenito |
7f0897 |
read_files_pattern($1,{ xend_var_lib_t xen_image_t },xen_image_t)
|
|
Chris PeBenito |
7f0897 |
')
|
|
Chris PeBenito |
7f0897 |
|
|
Chris PeBenito |
7f0897 |
########################################
|
|
Chris PeBenito |
7f0897 |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Allow the specified domain to append
|
|
Chris PeBenito |
17de1b |
## xend log files.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain allowed to transition.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_append_log',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type var_log_t, xend_var_log_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
logging_search_logs($1)
|
|
Chris PeBenito |
7f0897 |
append_files_pattern($1,xend_var_log_t,xend_var_log_t)
|
|
Chris PeBenito |
17de1b |
dontaudit $1 xend_var_log_t:file write;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
7f0897 |
## Create, read, write, and delete the
|
|
Chris PeBenito |
7f0897 |
## xend log files.
|
|
Chris PeBenito |
7f0897 |
## </summary>
|
|
Chris PeBenito |
7f0897 |
## <param name="domain">
|
|
Chris PeBenito |
7f0897 |
## <summary>
|
|
Chris PeBenito |
7f0897 |
## Domain allowed access.
|
|
Chris PeBenito |
7f0897 |
## </summary>
|
|
Chris PeBenito |
7f0897 |
## </param>
|
|
Chris PeBenito |
7f0897 |
#
|
|
Chris PeBenito |
7f0897 |
interface(`xen_manage_log',`
|
|
Chris PeBenito |
7f0897 |
gen_require(`
|
|
Chris PeBenito |
7f0897 |
type var_log_t, xend_var_log_t;
|
|
Chris PeBenito |
7f0897 |
')
|
|
Chris PeBenito |
7f0897 |
|
|
Chris PeBenito |
7f0897 |
logging_search_logs($1)
|
|
Chris PeBenito |
7f0897 |
manage_dirs_pattern($1,xend_var_log_t,xend_var_log_t)
|
|
Chris PeBenito |
7f0897 |
manage_files_pattern($1,xend_var_log_t,xend_var_log_t)
|
|
Chris PeBenito |
7f0897 |
')
|
|
Chris PeBenito |
7f0897 |
|
|
Chris PeBenito |
7f0897 |
########################################
|
|
Chris PeBenito |
7f0897 |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Do not audit attempts to read and write
|
|
Chris PeBenito |
17de1b |
## Xen unix domain stream sockets. These
|
|
Chris PeBenito |
17de1b |
## are leaked file descriptors.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain to not audit.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_dontaudit_rw_unix_stream_sockets',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type xend_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
dontaudit $1 xend_t:unix_stream_socket { read write };
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Connect to xenstored over an unix stream socket.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain allowed access.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_stream_connect_xenstore',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type xenstored_t, xenstored_var_run_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
files_search_pids($1)
|
|
Chris PeBenito |
c0868a |
stream_connect_pattern($1,xenstored_var_run_t,xenstored_var_run_t,xenstored_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Connect to xend over an unix domain stream socket.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain allowed access.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_stream_connect',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type xend_t, xend_var_run_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
files_search_pids($1)
|
|
Chris PeBenito |
c0868a |
stream_connect_pattern($1,xend_var_run_t,xend_var_run_t,xend_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Execute a domain transition to run xm.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## <param name="domain">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Domain allowed to transition.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`xen_domtrans_xm',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type xm_t, xm_exec_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
c0868a |
domtrans_pattern($1,xm_exec_t,xm_t)
|
|
Chris PeBenito |
17de1b |
')
|