add sxid, bug 1661
This commit is contained in:
parent
e8bf4dc9ec
commit
b6cc2f91f4
|
@ -74,6 +74,7 @@
|
|||
snort
|
||||
soundserver
|
||||
speedtouch
|
||||
sxid
|
||||
thunderbird
|
||||
tor (Erich Schubert)
|
||||
transproxy
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
/usr/bin/sxid -- gen_require(system_u:object_r:sxid_exec_t,s0)
|
||||
/usr/sbin/checksecurity\.se -- gen_require(system_u:object_r:sxid_exec_t,s0)
|
||||
|
||||
/var/log/setuid.* -- gen_require(system_u:object_r:sxid_log_t,s0)
|
||||
/var/log/setuid\.today.* -- gen_require(system_u:object_r:sxid_log_t,s0)
|
||||
/var/log/sxid\.log.* -- gen_require(system_u:object_r:sxid_log_t,s0)
|
|
@ -0,0 +1,21 @@
|
|||
## <summary>SUID/SGID program monitoring</summary>
|
||||
|
||||
########################################
|
||||
## <summary>
|
||||
## Allow the specified domain to read
|
||||
## sxid log files.
|
||||
## </summary>
|
||||
## <param name="domain">
|
||||
## <summary>
|
||||
## Domain allowed access.
|
||||
## </summary>
|
||||
## </param>
|
||||
#
|
||||
interface(`sxid_read_log',`
|
||||
gen_require(`
|
||||
type sxid_log_t;
|
||||
')
|
||||
|
||||
logging_search_logs($1)
|
||||
allow $1 sxid_log_t:file r_file_perms;
|
||||
')
|
|
@ -0,0 +1,111 @@
|
|||
|
||||
policy_module(sxid,1.0.0)
|
||||
|
||||
########################################
|
||||
#
|
||||
# Declarations
|
||||
#
|
||||
|
||||
type sxid_t;
|
||||
type sxid_exec_t;
|
||||
domain_type(sxid_t)
|
||||
domain_entry_file(sxid_t,sxid_exec_t)
|
||||
|
||||
type sxid_log_t;
|
||||
logging_log_file(sxid_log_t)
|
||||
|
||||
type sxid_tmp_t;
|
||||
files_tmp_file(sxid_tmp_t)
|
||||
|
||||
########################################
|
||||
#
|
||||
# Local policy
|
||||
#
|
||||
|
||||
allow sxid_t self:capability { dac_override dac_read_search fsetid };
|
||||
dontaudit sxid_t self:capability { setuid setgid sys_tty_config };
|
||||
allow sxid_t self:process signal_perms;
|
||||
allow sxid_t self:fifo_file rw_file_perms;
|
||||
allow sxid_t self:tcp_socket create_stream_socket_perms;
|
||||
allow sxid_t self:udp_socket create_socket_perms;
|
||||
|
||||
allow sxid_t sxid_log_t:file create_file_perms;
|
||||
logging_log_filetrans(sxid_t,sxid_log_t,file)
|
||||
|
||||
allow sxid_t sxid_tmp_t:dir create_dir_perms;
|
||||
allow sxid_t sxid_tmp_t:file create_file_perms;
|
||||
files_tmp_filetrans(sxid_t, sxid_tmp_t, { file dir })
|
||||
|
||||
kernel_read_system_state(sxid_t)
|
||||
kernel_read_kernel_sysctls(sxid_t)
|
||||
|
||||
corecmd_exec_bin(sxid_t)
|
||||
corecmd_exec_sbin(sxid_t)
|
||||
corecmd_exec_shell(sxid_t)
|
||||
|
||||
corenet_tcp_sendrecv_generic_if(sxid_t)
|
||||
corenet_udp_sendrecv_generic_if(sxid_t)
|
||||
corenet_raw_sendrecv_generic_if(sxid_t)
|
||||
corenet_tcp_sendrecv_all_nodes(sxid_t)
|
||||
corenet_udp_sendrecv_all_nodes(sxid_t)
|
||||
corenet_raw_sendrecv_all_nodes(sxid_t)
|
||||
corenet_tcp_sendrecv_all_ports(sxid_t)
|
||||
corenet_udp_sendrecv_all_ports(sxid_t)
|
||||
corenet_non_ipsec_sendrecv(sxid_t)
|
||||
corenet_tcp_bind_all_nodes(sxid_t)
|
||||
corenet_udp_bind_all_nodes(sxid_t)
|
||||
|
||||
dev_read_sysfs(sxid_t)
|
||||
dev_getattr_all_blk_files(sxid_t)
|
||||
dev_getattr_all_blk_files(sxid_t)
|
||||
|
||||
domain_use_interactive_fds(sxid_t)
|
||||
|
||||
files_list_all(sxid_t)
|
||||
files_getattr_all_symlinks(sxid_t)
|
||||
files_getattr_all_pipes(sxid_t)
|
||||
files_getattr_all_sockets(sxid_t)
|
||||
|
||||
fs_getattr_xattr_fs(sxid_t)
|
||||
fs_search_auto_mountpoints(sxid_t)
|
||||
fs_list_all(sxid_t)
|
||||
|
||||
term_dontaudit_use_console(sxid_t)
|
||||
|
||||
auth_read_all_files_except_shadow(sxid_t)
|
||||
|
||||
init_use_fds(sxid_t)
|
||||
init_use_script_ptys(sxid_t)
|
||||
|
||||
libs_use_ld_so(sxid_t)
|
||||
libs_use_shared_libs(sxid_t)
|
||||
|
||||
logging_send_syslog_msg(sxid_t)
|
||||
|
||||
miscfiles_read_localization(sxid_t)
|
||||
|
||||
mount_exec(sxid_t)
|
||||
|
||||
sysnet_read_config(sxid_t)
|
||||
|
||||
userdom_dontaudit_use_unpriv_user_fds(sxid_t)
|
||||
|
||||
cron_system_entry(sxid_t,sxid_exec_t)
|
||||
|
||||
ifdef(`targeted_policy',`
|
||||
term_dontaudit_use_unallocated_ttys(sxid_t)
|
||||
term_dontaudit_use_generic_ptys(sxid_t)
|
||||
files_dontaudit_read_root_files(sxid_t)
|
||||
')
|
||||
|
||||
optional_policy(`
|
||||
mta_send_mail(sxid_t)
|
||||
')
|
||||
|
||||
optional_policy(`
|
||||
seutil_sigchld_newrole(sxid_t)
|
||||
')
|
||||
|
||||
optional_policy(`
|
||||
udev_read_db(sxid_t)
|
||||
')
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
policy_module(mta,1.3.3)
|
||||
policy_module(mta,1.3.4)
|
||||
|
||||
########################################
|
||||
#
|
||||
|
@ -166,6 +166,10 @@ optional_policy(`
|
|||
qmail_domtrans_inject(system_mail_t)
|
||||
')
|
||||
|
||||
optional_policy(`
|
||||
sxid_read_log(system_mail_t)
|
||||
')
|
||||
|
||||
optional_policy(`
|
||||
userdom_dontaudit_use_unpriv_users_ptys(system_mail_t)
|
||||
|
||||
|
|
Loading…
Reference in New Issue