Chris PeBenito fa45da
## <summary>Cluster Configuration System</summary>
Chris PeBenito fa45da
Chris PeBenito fa45da
########################################
Chris PeBenito fa45da
## <summary>
Chris PeBenito fa45da
##	Execute a domain transition to run ccs.
Chris PeBenito fa45da
## </summary>
Chris PeBenito fa45da
## <param name="domain">
Chris PeBenito fa45da
## <summary>
Chris PeBenito fa45da
##	Domain allowed to transition.
Chris PeBenito fa45da
## </summary>
Chris PeBenito fa45da
## </param>
Chris PeBenito fa45da
#
Chris PeBenito fa45da
interface(`ccs_domtrans',`
Chris PeBenito fa45da
	gen_require(`
Chris PeBenito fa45da
		type ccs_t, ccs_exec_t;
Chris PeBenito fa45da
	')
Chris PeBenito fa45da
Chris PeBenito fa45da
	domain_auto_trans($1,ccs_exec_t,ccs_t)
Chris PeBenito fa45da
	allow ccs_t $1:fd use;
Chris PeBenito fa45da
	allow ccs_t $1:fifo_file rw_file_perms;
Chris PeBenito fa45da
	allow ccs_t $1:process sigchld;
Chris PeBenito fa45da
')
Chris PeBenito fa45da
Chris PeBenito fa45da
########################################
Chris PeBenito fa45da
## <summary>
Chris PeBenito fa45da
##	Connect to ccs over an unix stream socket.
Chris PeBenito fa45da
## </summary>
Chris PeBenito fa45da
## <param name="domain">
Chris PeBenito fa45da
##	<summary>
Chris PeBenito fa45da
##	Domain allowed access.
Chris PeBenito fa45da
##	</summary>
Chris PeBenito fa45da
## </param>
Chris PeBenito fa45da
#
Chris PeBenito fa45da
interface(`ccs_stream_connect',`
Chris PeBenito fa45da
	gen_require(`
Chris PeBenito fa45da
		type ccs_t, ccs_var_run_t;
Chris PeBenito fa45da
	')
Chris PeBenito fa45da
Chris PeBenito fa45da
	files_search_pids($1)
Chris PeBenito fa45da
	allow $1 ccs_var_run_t:dir list_dir_perms;
Chris PeBenito fa45da
	allow $1 ccs_var_run_t:sock_file write;
Chris PeBenito fa45da
	allow $1 ccs_t:unix_stream_socket connectto;
Chris PeBenito fa45da
')
Chris PeBenito fa45da
Chris PeBenito fa45da
########################################
Chris PeBenito fa45da
## <summary>
Chris PeBenito fa45da
##	Read cluster configuration files.
Chris PeBenito fa45da
## </summary>
Chris PeBenito fa45da
## <param name="domain">
Chris PeBenito fa45da
##	<summary>
Chris PeBenito fa45da
##	Domain allowed access.
Chris PeBenito fa45da
##	</summary>
Chris PeBenito fa45da
## </param>
Chris PeBenito fa45da
#
Chris PeBenito fa45da
interface(`ccs_read_config',`
Chris PeBenito fa45da
	gen_require(`
Chris PeBenito fa45da
		type cluster_conf_t;
Chris PeBenito fa45da
	')
Chris PeBenito fa45da
Chris PeBenito fa45da
	allow $1 cluster_conf_t:dir search_dir_perms;
Chris PeBenito fa45da
	allow $1 cluster_conf_t:file { getattr read };
Chris PeBenito fa45da
')
Chris PeBenito fa45da
Chris PeBenito fa45da
########################################
Chris PeBenito fa45da
## <summary>
Chris PeBenito fa45da
##	Manage cluster configuration files.
Chris PeBenito fa45da
## </summary>
Chris PeBenito fa45da
## <param name="domain">
Chris PeBenito fa45da
##	<summary>
Chris PeBenito fa45da
##	Domain allowed access.
Chris PeBenito fa45da
##	</summary>
Chris PeBenito fa45da
## </param>
Chris PeBenito fa45da
#
Chris PeBenito fa45da
interface(`ccs_manage_config',`
Chris PeBenito fa45da
	gen_require(`
Chris PeBenito fa45da
		type cluster_conf_t;
Chris PeBenito fa45da
	')
Chris PeBenito fa45da
Chris PeBenito fa45da
	allow $1 cluster_conf_t:dir manage_dir_perms;
Chris PeBenito fa45da
	allow $1 cluster_conf_t:file manage_file_perms;
Chris PeBenito fa45da
')