Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Daemon that interfaces mail transfer agents and content
Chris PeBenito 8a0a99
##	checkers, such as virus scanners.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
########################################
Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Execute a domain transition to run amavis.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
## <param name="domain">
Chris PeBenito 8a0a99
##	<summary>
Chris PeBenito 8a0a99
##	Domain allowed to transition.
Chris PeBenito 8a0a99
##	</summary>
Chris PeBenito 8a0a99
## </param>
Chris PeBenito 8a0a99
#
Chris PeBenito 8a0a99
interface(`amavis_domtrans',`
Chris PeBenito 8a0a99
	gen_require(`
Chris PeBenito 8a0a99
		type amavis_t, amavis_exec_t;
Chris PeBenito 8a0a99
	')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	domain_auto_trans($1,amavis_exec_t,amavis_t)
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	allow $1 amavis_t:fd use;
Chris PeBenito 8a0a99
	allow amavis_t $1:fd use;
Chris PeBenito 8a0a99
	allow amavis_t $1:fifo_file rw_file_perms;
Chris PeBenito 8a0a99
	allow amavis_t $1:process sigchld;
Chris PeBenito 8a0a99
')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
########################################
Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Search amavis lib directories.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
## <param name="domain">
Chris PeBenito 8a0a99
##	<summary>
Chris PeBenito 8a0a99
##	Domain allowed access.
Chris PeBenito 8a0a99
##	</summary>
Chris PeBenito 8a0a99
## </param>
Chris PeBenito 8a0a99
#
Chris PeBenito 8a0a99
interface(`amavis_search_lib',`
Chris PeBenito 8a0a99
	gen_require(`
Chris PeBenito 8a0a99
		type amavis_var_lib_t;
Chris PeBenito 8a0a99
	')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	allow $1 amavis_var_lib_t:dir search_dir_perms;
Chris PeBenito 8a0a99
	files_search_var_lib($1)
Chris PeBenito 8a0a99
')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
########################################
Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Read amavis lib files.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
## <param name="domain">
Chris PeBenito 8a0a99
##	<summary>
Chris PeBenito 8a0a99
##	Domain allowed access.
Chris PeBenito 8a0a99
##	</summary>
Chris PeBenito 8a0a99
## </param>
Chris PeBenito 8a0a99
#
Chris PeBenito 8a0a99
interface(`amavis_read_lib_files',`
Chris PeBenito 8a0a99
	gen_require(`
Chris PeBenito 8a0a99
		type amavis_var_lib_t;
Chris PeBenito 8a0a99
	')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	allow $1 amavis_var_lib_t:file r_file_perms;
Chris PeBenito 8a0a99
	allow $1 amavis_var_lib_t:dir list_dir_perms;
Chris PeBenito 8a0a99
	files_search_var_lib($1)
Chris PeBenito 8a0a99
')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
########################################
Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Create, read, write, and delete
Chris PeBenito 8a0a99
##	amavis lib files.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
## <param name="domain">
Chris PeBenito 8a0a99
##	<summary>
Chris PeBenito 8a0a99
##	Domain allowed access.
Chris PeBenito 8a0a99
##	</summary>
Chris PeBenito 8a0a99
## </param>
Chris PeBenito 8a0a99
#
Chris PeBenito 8a0a99
interface(`amavis_manage_lib_files',`
Chris PeBenito 8a0a99
	gen_require(`
Chris PeBenito 8a0a99
		type amavis_var_lib_t;
Chris PeBenito 8a0a99
	')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	allow $1 amavis_var_lib_t:file manage_file_perms;
Chris PeBenito 8a0a99
	allow $1 amavis_var_lib_t:dir rw_dir_perms;
Chris PeBenito 8a0a99
	files_search_var_lib($1)
Chris PeBenito 8a0a99
')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
########################################
Chris PeBenito 8a0a99
## <summary>
Chris PeBenito 8a0a99
##	Set the attributes of amavis pid files.
Chris PeBenito 8a0a99
## </summary>
Chris PeBenito 8a0a99
## <param name="domain">
Chris PeBenito 8a0a99
##	<summary>
Chris PeBenito 8a0a99
##	Domain allowed access.
Chris PeBenito 8a0a99
##	</summary>
Chris PeBenito 8a0a99
## </param>
Chris PeBenito 8a0a99
#
Chris PeBenito 8a0a99
interface(`amavis_setattr_pid_files',`
Chris PeBenito 8a0a99
	gen_require(`
Chris PeBenito 8a0a99
		type amavis_var_run_t;
Chris PeBenito 8a0a99
	')
Chris PeBenito 8a0a99
Chris PeBenito 8a0a99
	allow $1 amavis_var_run_t:file setattr;
Chris PeBenito 8a0a99
	files_search_pids($1)
Chris PeBenito 8a0a99
')