|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Daemon that interfaces mail transfer agents and content
|
|
Chris PeBenito |
17de1b |
## checkers, such as virus scanners.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Execute a domain transition to run amavis.
|
|
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(`amavis_domtrans',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_t, amavis_exec_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Dominick Grift |
88340b |
corecmd_search_bin($1)
|
|
Chris PeBenito |
0bfccd |
domtrans_pattern($1, amavis_exec_t, amavis_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Dominick Grift |
88340b |
## Execute amavis server in the amavis domain.
|
|
Dominick Grift |
88340b |
## </summary>
|
|
Dominick Grift |
88340b |
## <param name="domain">
|
|
Dominick Grift |
88340b |
## <summary>
|
|
Dominick Grift |
288845 |
## Domain allowed to transition.
|
|
Dominick Grift |
88340b |
## </summary>
|
|
Dominick Grift |
88340b |
## </param>
|
|
Dominick Grift |
88340b |
#
|
|
Dominick Grift |
88340b |
interface(`amavis_initrc_domtrans',`
|
|
Dominick Grift |
88340b |
gen_require(`
|
|
Jeremy Solt |
3b8148 |
type amavis_initrc_exec_t;
|
|
Dominick Grift |
88340b |
')
|
|
Dominick Grift |
88340b |
|
|
Dominick Grift |
88340b |
init_labeled_script_domtrans($1, amavis_initrc_exec_t)
|
|
Dominick Grift |
88340b |
')
|
|
Dominick Grift |
88340b |
|
|
Dominick Grift |
88340b |
########################################
|
|
Dominick Grift |
88340b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Read amavis spool files.
|
|
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(`amavis_read_spool_files',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_spool_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
files_search_spool($1)
|
|
Jeremy Solt |
b8097d |
read_files_pattern($1, amavis_spool_t, amavis_spool_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Manage amavis spool files.
|
|
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(`amavis_manage_spool_files',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_spool_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
files_search_spool($1)
|
|
Chris PeBenito |
0bfccd |
manage_dirs_pattern($1, amavis_spool_t, amavis_spool_t)
|
|
Chris PeBenito |
0bfccd |
manage_files_pattern($1, amavis_spool_t, amavis_spool_t)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Create objects in the amavis spool directories
|
|
Chris PeBenito |
17de1b |
## with a private type.
|
|
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 |
## <param name="private_type">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Private file type.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
## <param name="object_class">
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Class of the object being created.
|
|
Chris PeBenito |
17de1b |
## </summary>
|
|
Chris PeBenito |
17de1b |
## </param>
|
|
Chris PeBenito |
17de1b |
#
|
|
Chris PeBenito |
17de1b |
interface(`amavis_spool_filetrans',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_spool_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
files_search_spool($1)
|
|
Chris PeBenito |
0bfccd |
filetrans_pattern($1, amavis_spool_t, $2, $3)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Search amavis lib directories.
|
|
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(`amavis_search_lib',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_var_lib_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
allow $1 amavis_var_lib_t:dir search_dir_perms;
|
|
Chris PeBenito |
17de1b |
files_search_var_lib($1)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Read amavis lib files.
|
|
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(`amavis_read_lib_files',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_var_lib_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
0bfccd |
read_files_pattern($1, amavis_var_lib_t, amavis_var_lib_t)
|
|
Chris PeBenito |
17de1b |
allow $1 amavis_var_lib_t:dir list_dir_perms;
|
|
Chris PeBenito |
17de1b |
files_search_var_lib($1)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Create, read, write, and delete
|
|
Chris PeBenito |
17de1b |
## amavis lib files.
|
|
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(`amavis_manage_lib_files',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_var_lib_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
0bfccd |
manage_files_pattern($1, amavis_var_lib_t, amavis_var_lib_t)
|
|
Chris PeBenito |
17de1b |
files_search_var_lib($1)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Chris PeBenito |
17de1b |
########################################
|
|
Chris PeBenito |
17de1b |
## <summary>
|
|
Chris PeBenito |
17de1b |
## Set the attributes of amavis pid files.
|
|
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(`amavis_setattr_pid_files',`
|
|
Chris PeBenito |
17de1b |
gen_require(`
|
|
Chris PeBenito |
17de1b |
type amavis_var_run_t;
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
17de1b |
|
|
Dominick Grift |
9fa4de |
allow $1 amavis_var_run_t:file setattr_file_perms;
|
|
Chris PeBenito |
17de1b |
files_search_pids($1)
|
|
Chris PeBenito |
17de1b |
')
|
|
Chris PeBenito |
2c3ac4 |
|
|
Chris PeBenito |
2c3ac4 |
########################################
|
|
Chris PeBenito |
2c3ac4 |
## <summary>
|
|
Chris PeBenito |
2c3ac4 |
## Create of amavis pid files.
|
|
Chris PeBenito |
2c3ac4 |
## </summary>
|
|
Chris PeBenito |
2c3ac4 |
## <param name="domain">
|
|
Chris PeBenito |
2c3ac4 |
## <summary>
|
|
Chris PeBenito |
2c3ac4 |
## Domain allowed access.
|
|
Chris PeBenito |
2c3ac4 |
## </summary>
|
|
Chris PeBenito |
2c3ac4 |
## </param>
|
|
Chris PeBenito |
2c3ac4 |
#
|
|
Chris PeBenito |
2c3ac4 |
interface(`amavis_create_pid_files',`
|
|
Chris PeBenito |
2c3ac4 |
gen_require(`
|
|
Chris PeBenito |
2c3ac4 |
type amavis_var_run_t;
|
|
Chris PeBenito |
2c3ac4 |
')
|
|
Chris PeBenito |
2c3ac4 |
|
|
Chris PeBenito |
2c3ac4 |
allow $1 amavis_var_run_t:file create_file_perms;
|
|
Chris PeBenito |
2c3ac4 |
files_search_pids($1)
|
|
Chris PeBenito |
2c3ac4 |
')
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
########################################
|
|
Chris PeBenito |
ee6608 |
## <summary>
|
|
Jeremy Solt |
b8097d |
## All of the rules required to administrate
|
|
Chris PeBenito |
ee6608 |
## an amavis environment
|
|
Chris PeBenito |
ee6608 |
## </summary>
|
|
Chris PeBenito |
ee6608 |
## <param name="domain">
|
|
Chris PeBenito |
ee6608 |
## <summary>
|
|
Chris PeBenito |
ee6608 |
## Domain allowed access.
|
|
Chris PeBenito |
ee6608 |
## </summary>
|
|
Chris PeBenito |
ee6608 |
## </param>
|
|
Chris PeBenito |
967fd1 |
## <param name="role">
|
|
Chris PeBenito |
967fd1 |
## <summary>
|
|
Chris PeBenito |
967fd1 |
## Role allowed access.
|
|
Chris PeBenito |
967fd1 |
## </summary>
|
|
Chris PeBenito |
967fd1 |
## </param>
|
|
Chris PeBenito |
ee6608 |
## <rolecap/>
|
|
Chris PeBenito |
ee6608 |
#
|
|
Chris PeBenito |
ee6608 |
interface(`amavis_admin',`
|
|
Chris PeBenito |
ee6608 |
gen_require(`
|
|
Chris PeBenito |
b34db7 |
type amavis_t, amavis_tmp_t, amavis_var_log_t;
|
|
Chris PeBenito |
ee6608 |
type amavis_spool_t, amavis_var_lib_t, amavis_var_run_t;
|
|
Chris PeBenito |
ee6608 |
type amavis_etc_t, amavis_quarantine_t;
|
|
Jeremy Solt |
3b8148 |
type amavis_initrc_exec_t;
|
|
Chris PeBenito |
ee6608 |
')
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
allow $1 amavis_t:process { ptrace signal_perms };
|
|
Chris PeBenito |
ee6608 |
ps_process_pattern($1, amavis_t)
|
|
Chris PeBenito |
ee6608 |
|
|
Dominick Grift |
88340b |
amavis_initrc_domtrans($1)
|
|
Chris PeBenito |
967fd1 |
domain_system_change_exemption($1)
|
|
Chris PeBenito |
967fd1 |
role_transition $2 amavis_initrc_exec_t system_r;
|
|
Chris PeBenito |
967fd1 |
allow $2 system_r;
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
files_list_etc($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_etc_t)
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_quarantine_t)
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
files_list_spool($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_spool_t)
|
|
Chris PeBenito |
967fd1 |
|
|
Chris PeBenito |
967fd1 |
files_list_tmp($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_tmp_t)
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
files_list_var_lib($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_var_lib_t)
|
|
Chris PeBenito |
967fd1 |
|
|
Chris PeBenito |
967fd1 |
logging_list_logs($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_var_log_t)
|
|
Chris PeBenito |
ee6608 |
|
|
Chris PeBenito |
ee6608 |
files_list_pids($1)
|
|
Chris PeBenito |
967fd1 |
admin_pattern($1, amavis_var_run_t)
|
|
Chris PeBenito |
ee6608 |
')
|