## Framework for facilitating multiple user sessions on desktops. ######################################## ## ## Execute a domain transition to run consolekit. ## ## ## ## Domain allowed to transition. ## ## # interface(`consolekit_domtrans',` gen_require(` type consolekit_t, consolekit_exec_t; ') corecmd_search_bin($1) domtrans_pattern($1, consolekit_exec_t, consolekit_t) ') ######################################## ## ## dontaudit Send and receive messages from ## consolekit over dbus. ## ## ## ## Domain to not audit. ## ## # interface(`consolekit_dontaudit_dbus_chat',` gen_require(` type consolekit_t; class dbus send_msg; ') dontaudit $1 consolekit_t:dbus send_msg; dontaudit consolekit_t $1:dbus send_msg; ') ######################################## ## ## Send and receive messages from ## consolekit over dbus. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_dbus_chat',` gen_require(` type consolekit_t; class dbus send_msg; ') allow $1 consolekit_t:dbus send_msg; allow consolekit_t $1:dbus send_msg; ') ######################################## ## ## Dontaudit attempts to read consolekit log files. ## ## ## ## Domain to not audit. ## ## # interface(`consolekit_dontaudit_read_log',` gen_require(` type consolekit_log_t; ') dontaudit $1 consolekit_log_t:file read_file_perms; ') ######################################## ## ## Read consolekit log files. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_read_log',` gen_require(` type consolekit_log_t; ') read_files_pattern($1, consolekit_log_t, consolekit_log_t) logging_search_logs($1) ') ######################################## ## ## Create, read, write, and delete ## consolekit log files. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_manage_log',` gen_require(` type consolekit_log_t; ') manage_files_pattern($1, consolekit_log_t, consolekit_log_t) files_search_pids($1) ') ######################################## ## ## Read consolekit PID files. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_read_pid_files',` gen_require(` type consolekit_var_run_t; ') files_search_pids($1) allow $1 consolekit_var_run_t:dir list_dir_perms; read_files_pattern($1, consolekit_var_run_t, consolekit_var_run_t) ') ######################################## ## ## List consolekit PID files. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_list_pid_files',` gen_require(` type consolekit_var_run_t; ') files_search_pids($1) list_dirs_pattern($1, consolekit_var_run_t, consolekit_var_run_t) ') ######################################## ## ## Allow the domain to read consolekit state files in /proc. ## ## ## ## Domain allowed access. ## ## # interface(`consolekit_read_state',` gen_require(` type consolekit_t; ') kernel_search_proc($1) ps_process_pattern($1, consolekit_t) ') ######################################## ## ## Execute consolekit server in the consolekit domain. ## ## ## ## Domain allowed to transition. ## ## # interface(`consolekit_systemctl',` gen_require(` type consolekit_t; type consolekit_unit_file_t; ') systemd_exec_systemctl($1) init_reload_services($1) allow $1 consolekit_unit_file_t:file read_file_perms; allow $1 consolekit_unit_file_t:service manage_service_perms; ps_process_pattern($1, consolekit_t) ')