2005-10-22 23:50:23 +00:00
|
|
|
## <summary>Filter used for removing unsolicited email.</summary>
|
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
########################################
|
2005-12-01 18:01:21 +00:00
|
|
|
## <summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## Role access for spamassassin
|
2005-12-01 18:01:21 +00:00
|
|
|
## </summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## <param name="role">
|
2006-02-10 18:41:53 +00:00
|
|
|
## <summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## Role allowed access
|
2006-02-10 18:41:53 +00:00
|
|
|
## </summary>
|
2005-12-01 18:01:21 +00:00
|
|
|
## </param>
|
2008-11-05 16:10:46 +00:00
|
|
|
## <param name="domain">
|
2006-02-10 18:41:53 +00:00
|
|
|
## <summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## User domain for the role
|
2006-02-10 18:41:53 +00:00
|
|
|
## </summary>
|
2005-12-01 18:01:21 +00:00
|
|
|
## </param>
|
|
|
|
#
|
2008-11-05 16:10:46 +00:00
|
|
|
interface(`spamassassin_role',`
|
2007-02-16 23:01:42 +00:00
|
|
|
gen_require(`
|
2008-11-05 16:10:46 +00:00
|
|
|
type spamc_t, spamc_exec_t, spamc_tmp_t;
|
|
|
|
type spamassassin_t, spamassassin_exec_t;
|
|
|
|
type spamassassin_home_t, spamassassin_tmp_t;
|
2005-12-01 18:01:21 +00:00
|
|
|
')
|
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
role $1 types { spamc_t spamassassin_t };
|
2007-10-02 16:04:50 +00:00
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
domtrans_pattern($2, spamassassin_exec_t, spamassassin_t)
|
|
|
|
ps_process_pattern($2, spamassassin_t)
|
2006-03-13 21:36:49 +00:00
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
domtrans_pattern($2, spamc_exec_t, spamc_t)
|
|
|
|
ps_process_pattern($2, spamc_t)
|
2005-12-01 22:53:20 +00:00
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
manage_dirs_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
|
|
|
manage_files_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
|
|
|
manage_lnk_files_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
|
|
|
relabel_dirs_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
|
|
|
relabel_files_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
|
|
|
relabel_lnk_files_pattern($2, spamassassin_home_t, spamassassin_home_t)
|
2005-12-01 18:01:21 +00:00
|
|
|
')
|
2005-11-15 20:17:18 +00:00
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Execute the standalone spamassassin
|
|
|
|
## program in the caller directory.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2006-02-10 18:41:53 +00:00
|
|
|
## <summary>
|
2005-11-15 20:17:18 +00:00
|
|
|
## Domain allowed access.
|
2006-02-10 18:41:53 +00:00
|
|
|
## </summary>
|
2005-11-15 20:17:18 +00:00
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_exec',`
|
|
|
|
gen_require(`
|
|
|
|
type spamassassin_exec_t;
|
|
|
|
')
|
|
|
|
|
2008-07-23 21:38:39 +00:00
|
|
|
can_exec($1, spamassassin_exec_t)
|
2005-11-15 20:17:18 +00:00
|
|
|
|
|
|
|
')
|
|
|
|
|
2006-03-13 21:36:49 +00:00
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Singnal the spam assassin daemon
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## The type of the process performing this action.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_signal_spamd',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
allow $1 spamd_t:process signal;
|
|
|
|
')
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Execute the spamassassin daemon
|
|
|
|
## program in the caller directory.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_exec_spamd',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_exec_t;
|
|
|
|
')
|
|
|
|
|
2008-07-23 21:38:39 +00:00
|
|
|
can_exec($1, spamd_exec_t)
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## Execute spamassassin client in the spamassassin client domain.
|
2006-03-13 21:36:49 +00:00
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2008-11-05 16:10:46 +00:00
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
2006-03-13 21:36:49 +00:00
|
|
|
## </param>
|
|
|
|
#
|
2008-11-05 16:10:46 +00:00
|
|
|
interface(`spamassassin_domtrans_client',`
|
2006-03-13 21:36:49 +00:00
|
|
|
gen_require(`
|
2008-11-05 16:10:46 +00:00
|
|
|
type spamc_t, spamc_exec_t;
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
domtrans_pattern($1, spamc_exec_t, spamc_t)
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
2005-11-15 20:17:18 +00:00
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Execute the spamassassin client
|
|
|
|
## program in the caller directory.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2006-02-10 18:41:53 +00:00
|
|
|
## <summary>
|
2005-11-15 20:17:18 +00:00
|
|
|
## Domain allowed access.
|
2006-02-10 18:41:53 +00:00
|
|
|
## </summary>
|
2005-11-15 20:17:18 +00:00
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_exec_client',`
|
|
|
|
gen_require(`
|
|
|
|
type spamc_exec_t;
|
|
|
|
')
|
|
|
|
|
2008-07-23 21:38:39 +00:00
|
|
|
can_exec($1, spamc_exec_t)
|
2005-11-15 20:17:18 +00:00
|
|
|
')
|
2006-03-13 21:36:49 +00:00
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
2008-11-05 16:10:46 +00:00
|
|
|
## Execute spamassassin standalone client in the user spamassassin domain.
|
2006-03-13 21:36:49 +00:00
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2008-11-05 16:10:46 +00:00
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
2006-03-13 21:36:49 +00:00
|
|
|
## </param>
|
|
|
|
#
|
2008-11-05 16:10:46 +00:00
|
|
|
interface(`spamassassin_domtrans_local_client',`
|
2006-03-13 21:36:49 +00:00
|
|
|
gen_require(`
|
2008-11-05 16:10:46 +00:00
|
|
|
type spamassassin_t, spamassassin_exec_t;
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
2008-11-05 16:10:46 +00:00
|
|
|
domtrans_pattern($1, spamassassin_exec_t, spamassassin_t)
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
2007-03-07 21:33:22 +00:00
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## read spamd lib files.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_read_lib_files',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_var_lib_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
files_search_var_lib($1)
|
2008-07-23 21:38:39 +00:00
|
|
|
read_files_pattern($1, spamd_var_lib_t, spamd_var_lib_t)
|
2007-03-07 21:33:22 +00:00
|
|
|
')
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Create, read, write, and delete
|
|
|
|
## spamd lib files.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_manage_lib_files',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_var_lib_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
files_search_var_lib($1)
|
2008-07-23 21:38:39 +00:00
|
|
|
manage_files_pattern($1, spamd_var_lib_t, spamd_var_lib_t)
|
2007-03-07 21:33:22 +00:00
|
|
|
')
|
|
|
|
|
2006-03-13 21:36:49 +00:00
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Read temporary spamd file.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## The type of the process performing this action.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_read_spamd_tmp_files',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_tmp_t;
|
|
|
|
')
|
|
|
|
|
2006-12-12 20:08:08 +00:00
|
|
|
allow $1 spamd_tmp_t:file read_file_perms;
|
2006-03-13 21:36:49 +00:00
|
|
|
')
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Do not audit attempts to get attributes of temporary
|
|
|
|
## spamd sockets/
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## Domain to not audit.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`spamassassin_dontaudit_getattr_spamd_tmp_sockets',`
|
|
|
|
gen_require(`
|
|
|
|
type spamd_tmp_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
dontaudit $1 spamd_tmp_t:sock_file getattr;
|
|
|
|
')
|