Oreon-Lime-R2/selinux-policy/selinux-policy-d9f4a2b/selinux-policy-d9f4a2bbeb91fd95d0c35a90936efb9ea99d2455/policy/modules/contrib/accountsd.if

214 lines
4.3 KiB
Text
Raw Permalink Normal View History

## <summary>AccountsService and daemon for manipulating user account information via D-Bus.</summary>
########################################
## <summary>
## Execute a domain transition to
## run accountsd.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed to transition.
## </summary>
## </param>
#
interface(`accountsd_domtrans',`
gen_require(`
type accountsd_t, accountsd_exec_t;
')
corecmd_search_bin($1)
domtrans_pattern($1, accountsd_exec_t, accountsd_t)
')
########################################
## <summary>
## Read accountsd fifo files.
## </summary>
## <param name="domain">
## <summary>
## Domain to not audit.
## </summary>
## </param>
#
interface(`accountsd_read_fifo_file',`
gen_require(`
type accountsd_t;
')
allow $1 accountsd_t:fifo_file read_fifo_file_perms;
')
########################################
## <summary>
## Do not audit attempts to read and
## write Accounts Daemon fifo files.
## </summary>
## <param name="domain">
## <summary>
## Domain to not audit.
## </summary>
## </param>
#
interface(`accountsd_dontaudit_rw_fifo_file',`
gen_require(`
type accountsd_t;
')
dontaudit $1 accountsd_t:fifo_file rw_fifo_file_perms;
')
########################################
## <summary>
## Send and receive messages from
## accountsd over dbus.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_dbus_chat',`
gen_require(`
type accountsd_t;
class dbus send_msg;
')
allow $1 accountsd_t:dbus send_msg;
allow accountsd_t $1:dbus send_msg;
')
########################################
## <summary>
## Search accountsd lib directories.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_search_lib',`
gen_require(`
type accountsd_var_lib_t;
')
allow $1 accountsd_var_lib_t:dir search_dir_perms;
files_search_var_lib($1)
')
########################################
## <summary>
## Watch accountsd lib directories.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_watch_lib',`
gen_require(`
type accountsd_var_lib_t;
')
files_search_var_lib($1)
watch_dirs_pattern($1, accountsd_var_lib_t, accountsd_var_lib_t)
')
########################################
## <summary>
## Read accountsd lib files.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_read_lib_files',`
gen_require(`
type accountsd_var_lib_t;
')
files_search_var_lib($1)
allow $1 accountsd_var_lib_t:dir list_dir_perms;
read_files_pattern($1, accountsd_var_lib_t, accountsd_var_lib_t)
')
########################################
## <summary>
## Create, read, write, and delete
## accountsd lib files.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_manage_lib_files',`
gen_require(`
type accountsd_var_lib_t;
')
files_search_var_lib($1)
manage_files_pattern($1, accountsd_var_lib_t, accountsd_var_lib_t)
')
########################################
## <summary>
## All of the rules required to
## administrate an accountsd environment.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed to transition.
## </summary>
## </param>
#
interface(`accountsd_systemctl',`
gen_require(`
type accountsd_t;
type accountsd_unit_file_t;
')
systemd_exec_systemctl($1)
init_reload_services($1)
allow $1 accountsd_unit_file_t:file read_file_perms;
allow $1 accountsd_unit_file_t:service manage_service_perms;
ps_process_pattern($1, accountsd_t)
')
########################################
## <summary>
## All of the rules required to administrate
## an accountsd environment
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`accountsd_admin',`
gen_require(`
type accountsd_t;
type accountsd_unit_file_t;
')
allow $1 accountsd_t:process signal_perms;
ps_process_pattern($1, accountsd_t)
tunable_policy(`deny_ptrace',`',`
allow $1 accountsd_t:process ptrace;
')
accountsd_manage_lib_files($1)
accountsd_systemctl($1)
admin_pattern($1, accountsd_unit_file_t)
allow $1 accountsd_unit_file_t:service all_service_perms;
')