Latest diffs
mls constraints changed by evaluator
consoletype/hostname need to ignore open fds from xen. Xen leaks them and uses them to communicate. Maybe someday they will fix this.
firstboot needs to dbus chat with hal
apt runs as rpm on Red Hat platforms
userad
d and groupadd need to transition to nscd
mozilla fixes for strict policy
qemu-ifup should be bin_t
xfs now supports xattrs
Added new access to kernel:key
xen wants to getattr on devpts filesystem
Fixes for amavis
Apache should not ignore access to sysadm home dirs
avahi needs access to certs for encryption
bluetooth running on ypbind systems
Fixes for crontab in strict/mls policies
Fixes for newversion of cupsd that is SELinux aware
user dbus needs to talk to hal in strict policy
ldap has a socket
ntp needs net_bind_service
Fixes for postfix
Samba needs to be able to create a log directory
setroubleshoot has been cleaned up to be one process.
spam wants to read postfix config
squid needs to be able to setrlimit, and sys_resource
xserver in strict policy needs additional privs
libavutil changed its name
login programs need self:key {search write }. Should this be moved to auth_pgm?
Audit is being changed to use a socket.
Avahi has its own localtime
mount wants to check if selinux in enforcing mode
semanage_t needs to be able to read files created by secadm_t
uncofined_execmem_t needs to be chating
We need to coordinat the changes to userdomain.
policy/mls +1 -8
@@ -184,19 +184,12 @@ ( t2 == mlstrustedobject )); # the "single level" file "write" ops -mlsconstrain { file lnk_file fifo_file } { write create setattr relabelfrom append unlink link rename mounton } +mlsconstrain { file lnk_file fifo_file dir chr_file blk_file sock_file } { write create setattr relabelfrom append unlink link rename mounton } (( l1 eq l2 ) or (( t1 == mlsfilewritetoclr ) and ( h1 dom l2 ) and ( l1 domby l2 )) or ( t1 == mlsfilewrite ) or ( t2 == mlstrustedobject )); -# the "ranged" file "write" ops -mlsconstrain { dir chr_file blk_file sock_file } { write create setattr relabelfrom append unlink link rename mounton } - ((( l1 dom l2 ) and ( l1 domby h2 )) or - (( t1 == mlsfilewritetoclr ) and ( h1 dom l2 ) and ( l1 domby l2 )) or - ( t1 == mlsfilewrite ) or - ( t2 == mlstrustedobject )); - mlsconstrain dir { add_name remove_name reparent rmdir } ((( l1 dom l2 ) and ( l1 domby h2 )) or (( t1 == mlsfilewritetoclr ) and ( h1 dom l2 ) and ( l1 domby l2 )) or
policy/modules/admin/consoletype.te +10 -1
@@ -8,7 +8,12 @@ type consoletype_t; type consoletype_exec_t; -init_domain(consoletype_t,consoletype_exec_t) +#dont transition from initrc +#init_domain(consoletype_t,consoletype_exec_t) +domain_type(consoletype_t) +domain_entry_file(consoletype_t,consoletype_exec_t) +role system_r types consoletype_t; + mls_file_read_up(consoletype_t) mls_file_write_down(consoletype_t) role system_r types consoletype_t;
@@ -114,3 +119,7 @@ xen_append_log(consoletype_t) xen_dontaudit_rw_unix_stream_sockets(consoletype_t) ') + +optional_policy(` + xen_dontaudit_use_fds(consoletype_t) +')
policy/modules/admin/firstboot.te +1 -1
@@ -106,7 +106,7 @@ ') optional_policy(` - hal_dbus_send(firstboot_t) + hal_dbus_chat(firstboot_t) ') optional_policy(`
policy/modules/admin/rpm.fc +2 -0
@@ -19,6 +19,8 @@ /usr/sbin/pup -- gen_context(system_u:object_r:rpm_exec_t,s0) /usr/sbin/rhn_check -- gen_context(system_u:object_r:rpm_exec_t,s0) /usr/sbin/up2date -- gen_context(system_u:object_r:rpm_exec_t,s0) +/usr/bin/apt-get -- gen_context(system_u:object_r:rpm_exec_t,s0) +/usr/bin/apt-shell -- gen_context(system_u:object_r:rpm_exec_t,s0) ') /var/lib/alternatives(/.*)? gen_context(system_u:object_r:rpm_var_lib_t,s0)
policy/modules/admin/usermanage.te +2 -2
@@ -260,7 +260,7 @@ ') optional_policy(` - nscd_exec(groupadd_t) + nscd_domtrans(groupadd_t) nscd_socket_use(groupadd_t) ')
@@ -535,7 +535,7 @@ ') optional_policy(` - nscd_exec(useradd_t) + nscd_domtrans(useradd_t) nscd_socket_use(useradd_t) ')
policy/modules/apps/mozilla.if +2 -0
@@ -63,6 +63,7 @@ allow $1_mozilla_t self:unix_stream_socket { listen accept }; # Browse the web, connect to printer allow $1_mozilla_t self:tcp_socket create_socket_perms; + allow $1_mozilla_t self:netlink_route_socket r_netlink_socket_perms; # for bash - old mozilla binary can_exec($1_mozilla_t, mozilla_exec_t)
@@ -175,6 +176,7 @@ logging_send_syslog_msg($1_mozilla_t) miscfiles_read_fonts($1_mozilla_t) + miscfiles_read_localization($1_mozilla_t) # Browse the web, connect to printer sysnet_dns_name_resolve($1_mozilla_t)
policy/modules/kernel/corecommands.fc +1 -0
@@ -62,6 +62,7 @@ /etc/X11/xinit(/.*)? gen_context(system_u:object_r:bin_t,s0) /etc/xen/scripts(/.*)? gen_context(system_u:object_r:bin_t,s0) +/etc/xen/qemu-ifup -- gen_context(system_u:object_r:bin_t,s0) ifdef(`distro_debian',` /etc/mysql/debian-start -- gen_context(system_u:object_r:bin_t,s0)
policy/modules/kernel/corenetwork.te.in +1 -0
@@ -73,6 +73,7 @@ network_port(dhcpc, udp,68,s0) network_port(dhcpd, udp,67,s0, tcp,647,s0, udp,647,s0, tcp,847,s0, udp,847,s0) network_port(dict, tcp,2628,s0) +network_port(setroubleshoot, tcp,3267,s0) network_port(distccd, tcp,3632,s0) network_port(dns, udp,53,s0, tcp,53,s0) network_port(fingerd, tcp,79,s0)
policy/modules/kernel/filesystem.te +1 -1
@@ -24,6 +24,7 @@ fs_use_xattr ext2 gen_context(system_u:object_r:fs_t,s0); fs_use_xattr ext3 gen_context(system_u:object_r:fs_t,s0); fs_use_xattr gfs2 gen_context(system_u:object_r:fs_t,s0); +fs_use_xattr gfs gen_context(system_u:object_r:fs_t,s0); fs_use_xattr jfs gen_context(system_u:object_r:fs_t,s0); fs_use_xattr xfs gen_context(system_u:object_r:fs_t,s0);
@@ -181,7 +182,6 @@ genfscon hfs / gen_context(system_u:object_r:nfs_t,s0) genfscon hfsplus / gen_context(system_u:object_r:nfs_t,s0) genfscon reiserfs / gen_context(system_u:object_r:nfs_t,s0) -genfscon gfs / gen_context(system_u:object_r:nfs_t,s0) ######################################## #
policy/modules/kernel/kernel.if +75 -0
84 lines not on this page · raw message
policy/modules/kernel/terminal.if +19 -0
@@ -308,6 +308,7 @@ type devpts_t; ') + dev_dontaudit_list_all_dev_nodes($1) dontaudit $1 devpts_t:dir search; ')
@@ -948,3 +949,21 @@ dontaudit $1 ttynode:chr_file { read write }; ') +######################################## +## <summary> +## Get the attributes of a pty filesystem +## </summary> +## <param name="domain"> +## <summary> +## Domain allowed access. +## </summary> +## </param> +# +interface(`term_getattr_ptys_fs',` + gen_require(` + type devpts_t; + ') + + allow $1 devpts_t:filesystem getattr; +') +
policy/modules/services/amavis.te +7 -0
@@ -62,10 +62,12 @@ allow amavis_t amavis_quarantine_t:dir create_dir_perms; # Spool Files +files_search_spool(amavis_t) allow amavis_t amavis_spool_t:dir manage_dir_perms; allow amavis_t amavis_spool_t:file manage_file_perms; allow amavis_t amavis_spool_t:sock_file manage_file_perms; files_spool_filetrans(amavis_t,amavis_spool_t,{ dir file }) +type_transition amavis_t amavis_spool_t:sock_file amavis_var_run_t; # tmp files allow amavis_t amavis_tmp_t:file create_file_perms;
@@ -116,6 +118,7 @@ # bind to incoming port corenet_tcp_bind_amavisd_recv_port(amavis_t) corenet_udp_bind_generic_port(amavis_t) +corenet_tcp_connect_razor_port(amavis_t) dev_read_rand(amavis_t) dev_read_urand(amavis_t)
@@ -180,3 +183,7 @@ spamassassin_exec(amavis_t) spamassassin_exec_client(amavis_t) ') + +optional_policy(` + postfix_read_config(amavis_t) +')
policy/modules/services/apache.te +0 -1
@@ -273,7 +273,6 @@ sysnet_read_config(httpd_t) userdom_use_unpriv_users_fds(httpd_t) -userdom_dontaudit_search_sysadm_home_dirs(httpd_t) mta_send_mail(httpd_t)
policy/modules/services/avahi.te +1 -0
@@ -79,6 +79,7 @@ sysnet_read_config(avahi_t) sysnet_use_ldap(avahi_t) +miscfiles_read_certs(avahi_t) userdom_dontaudit_use_unpriv_user_fds(avahi_t) userdom_dontaudit_search_sysadm_home_dirs(avahi_t)
policy/modules/services/bluetooth.te +5 -0
@@ -247,3 +247,8 @@ optional_policy(` xserver_stream_connect_xdm(bluetooth_helper_t) ') + +optional_policy(` + nis_use_ypbind(bluetooth_helper_t) +') +
policy/modules/services/clamav.if +1 -0
@@ -102,3 +102,4 @@ allow clamscan_t $1:fifo_file rw_file_perms; allow clamscan_t $1:process sigchld; ') +
policy/modules/services/cron.if +13 -3
@@ -181,6 +181,7 @@ allow $1_crontab_t $2:fd use; allow $1_crontab_t $2:fifo_file rw_file_perms; allow $1_crontab_t $2:process sigchld; + allow $2 $1_crontab_t:process sigchld; # crontab shows up in user ps allow $2 $1_crontab_t:dir { search getattr read };
@@ -194,14 +195,19 @@ # Allow crond to read those crontabs in cron spool. allow crond_t $1_cron_spool_t:file create_file_perms; + allow $1_crontab_t tmp_t:dir rw_dir_perms; + allow $1_crontab_t $1_tmp_t:file create_file_perms; + type_transition $1_crontab_t tmp_t:file $1_tmp_t; + # dac_override is to create the file in the directory under /tmp - allow $1_crontab_t self:capability { setuid setgid chown dac_override }; + allow $1_crontab_t self:capability { fowner setuid setgid chown dac_override }; allow $1_crontab_t self:process signal_perms; # create files in /var/spool/cron - allow $1_crontab_t $1_cron_spool_t:file create_file_perms; + files_search_spool($1_crontab_t) allow $1_crontab_t cron_spool_t:dir rw_dir_perms; - type_transition $1_crontab_t $1_cron_spool_t:file $1_cron_spool_t; + allow $1_crontab_t $1_cron_spool_t:file create_file_perms; + type_transition $1_crontab_t cron_spool_t:file $1_cron_spool_t; # crontab signals crond by updating the mtime on the spooldir allow $1_crontab_t cron_spool_t:dir setattr;
@@ -239,6 +245,10 @@ # Read user crontabs userdom_read_user_home_content_files($1,$1_crontab_t) + optional_policy(` + nscd_socket_use($1_crontab_t) + ') + tunable_policy(`fcron_crond', ` # fcron wants an instant update of a crontab change for the administrator # also crontab does a security check for crontab -u
policy/modules/services/cups.te +5 -1
@@ -81,6 +81,7 @@ allow cupsd_t self:unix_stream_socket { create_stream_socket_perms connectto }; allow cupsd_t self:unix_dgram_socket create_socket_perms; allow cupsd_t self:netlink_audit_socket { create_netlink_socket_perms nlmsg_relay }; +allow cupsd_t self:netlink_selinux_socket create_socket_perms; allow cupsd_t self:netlink_route_socket r_netlink_socket_perms; allow cupsd_t self:tcp_socket { create_stream_socket_perms connectto acceptfrom recvfrom }; allow cupsd_t self:udp_socket create_socket_perms;
@@ -153,6 +154,8 @@ dev_read_sysfs(cupsd_t) dev_read_usbfs(cupsd_t) +domain_read_all_domains_state(cupsd_t) + fs_getattr_all_fs(cupsd_t) fs_search_auto_mountpoints(cupsd_t) # from old usercanread attrib:
@@ -202,7 +205,8 @@ # invoking ghostscript needs to read fonts miscfiles_read_fonts(cupsd_t) -seutil_dontaudit_read_config(cupsd_t) +seutil_read_config(cupsd_t) +selinux_compute_access_vector(cupsd_t) sysnet_read_config(cupsd_t)
policy/modules/services/dbus.if +5 -0
@@ -171,6 +171,11 @@ xserver_use_xdm_fds($1_dbusd_t) xserver_rw_xdm_pipes($1_dbusd_t) ') + + optional_policy(` + hal_dbus_chat($1_dbusd_t) + ') + ') #######################################
policy/modules/services/ldap.te +1 -1
@@ -72,7 +72,7 @@ allow slapd_t slapd_var_run_t:file create_file_perms; allow slapd_t slapd_var_run_t:dir rw_dir_perms; -files_pid_filetrans(slapd_t,slapd_var_run_t,file) +files_pid_filetrans(slapd_t,slapd_var_run_t,{ file socket }) kernel_read_system_state(slapd_t) kernel_read_kernel_sysctls(slapd_t)
policy/modules/services/nis.te +0 -2
@@ -249,8 +249,6 @@ allow ypserv_t self:unix_dgram_socket create_socket_perms; allow ypserv_t self:unix_stream_socket create_stream_socket_perms; allow ypserv_t self:netlink_route_socket r_netlink_socket_perms; -allow ypserv_t self:tcp_socket connected_stream_socket_perms; -allow ypserv_t self:udp_socket create_socket_perms; allow ypserv_t var_yp_t:dir rw_dir_perms; allow ypserv_t var_yp_t:file create_file_perms;
policy/modules/services/ntp.te +1 -1
@@ -32,7 +32,7 @@ # sys_resource and setrlimit is for locking memory # ntpdate wants sys_nice -allow ntpd_t self:capability { chown dac_override kill setgid setuid sys_time ipc_lock sys_chroot sys_nice sys_resource }; +allow ntpd_t self:capability { chown dac_override kill setgid setuid sys_time ipc_lock net_bind_service sys_chroot sys_nice sys_resource }; dontaudit ntpd_t self:capability { net_admin sys_tty_config fsetid sys_nice }; allow ntpd_t self:process { signal_perms setcap setsched setrlimit }; allow ntpd_t self:fifo_file { read write getattr };
policy/modules/services/pegasus.if +31 -0
@@ -1 +1,32 @@ ## <summary>The Open Group Pegasus CIM/WBEM Server.</summary> + +######################################## +## <summary> +## Execute a domain transition to run pegasus. +## </summary> +## <param name="domain"> +## <summary> +## Domain allowed to transition. +## </summary> +## </param> +# +interface(`pegasus_domtrans',` + gen_require(` + type pegasus_t, pegasus_exec_t; + ') + + ifdef(`targeted_policy',` + if(pegasus_disable_trans) { + can_exec($1,pegasus_exec_t) + } else { + domain_auto_trans($1,pegasus_exec_t,pegasus_t) + } + ', ` + domain_auto_trans($1,pegasus_exec_t,pegasus_t) + ') + + allow $1 pegasus_t:fd use; + allow pegasus_t $1:fd use; + allow pegasus_t $1:fifo_file rw_file_perms; + allow pegasus_t $1:process sigchld; +')
policy/modules/services/pegasus.te +2 -3
@@ -100,13 +100,12 @@ auth_use_nsswitch(pegasus_t) auth_domtrans_chk_passwd(pegasus_t) +auth_read_shadow(pegasus_t) domain_use_interactive_fds(pegasus_t) domain_read_all_domains_state(pegasus_t) -files_read_etc_files(pegasus_t) -files_list_var_lib(pegasus_t) -files_read_var_lib_files(pegasus_t) +files_read_all_files(pegasus_t) files_read_var_lib_symlinks(pegasus_t) hostname_exec(pegasus_t)
policy/modules/services/postfix.te +7 -0
@@ -250,6 +250,7 @@ allow postfix_cleanup_t postfix_spool_t:lnk_file create_lnk_perms; allow postfix_cleanup_t postfix_spool_bounce_t:dir r_dir_perms; +corecmd_exec_bin(postfix_cleanup_t) ######################################## #
@@ -293,6 +294,10 @@ procmail_domtrans(postfix_local_t) ') +optional_policy(` + clamav_search_lib(postfix_local_t) +') + ######################################## # # Postfix map local policy
@@ -519,6 +524,7 @@ allow postfix_qmgr_t postfix_spool_bounce_t:dir { getattr read search }; allow postfix_qmgr_t postfix_spool_bounce_t:file { read getattr }; allow postfix_qmgr_t postfix_spool_bounce_t:lnk_file { getattr read }; +corecmd_exec_bin(postfix_qmgr_t) ######################################## #
@@ -589,6 +595,7 @@ # for OpenSSL certificates files_read_usr_files(postfix_smtpd_t) mta_read_aliases(postfix_smtpd_t) +corecmd_exec_bin(postfix_smtpd_t) optional_policy(` postgrey_stream_connect(postfix_smtpd_t)
policy/modules/services/procmail.te +1 -0
@@ -29,6 +29,7 @@ kernel_read_kernel_sysctls(procmail_t) corenet_non_ipsec_sendrecv(procmail_t) +corenet_udp_bind_inaddr_any_node(procmail_t) corenet_tcp_sendrecv_all_if(procmail_t) corenet_udp_sendrecv_all_if(procmail_t) corenet_tcp_sendrecv_all_nodes(procmail_t)
policy/modules/services/samba.te +2 -2
@@ -191,7 +191,7 @@ allow smbd_t samba_etc_t:dir rw_dir_perms; allow smbd_t samba_etc_t:file { rw_file_perms setattr }; -allow smbd_t samba_log_t:dir { ra_dir_perms setattr }; +allow smbd_t samba_log_t:dir { create ra_dir_perms setattr }; dontaudit smbd_t samba_log_t:dir remove_name; allow smbd_t samba_log_t:file { create ra_file_perms };
@@ -367,7 +367,7 @@ allow nmbd_t samba_etc_t:dir { search getattr }; allow nmbd_t samba_etc_t:file { getattr read }; -allow nmbd_t samba_log_t:dir { ra_dir_perms setattr }; +allow nmbd_t samba_log_t:dir { create ra_dir_perms setattr }; allow nmbd_t samba_log_t:file { create ra_file_perms }; allow nmbd_t samba_var_t:dir rw_dir_perms;
policy/modules/services/setroubleshoot.fc +9 -0
@@ -0,0 +1,9 @@ +# setroubleshoot executables + +/usr/sbin/setroubleshootd -- gen_context(system_u:object_r:setroubleshootd_exec_t,s0) + +/var/run/setroubleshoot(/.*)? gen_context(system_u:object_r:setroubleshoot_var_run_t,s0) + +/var/log/setroubleshoot(/.*)? gen_context(system_u:object_r:setroubleshoot_var_log_t,s0) + +/var/lib/setroubleshoot(/.*)? gen_context(system_u:object_r:setroubleshoot_var_lib_t,s0)
policy/modules/services/setroubleshoot.if +3 -0
@@ -0,0 +1,3 @@ +## <summary>policy for setroubleshoot</summary> + +
policy/modules/services/setroubleshoot.te +101 -0
101 lines not on this page · raw message
policy/modules/services/spamassassin.te +4 -0
@@ -194,3 +194,7 @@ optional_policy(` udev_read_db(spamd_t) ') + +optional_policy(` + postfix_read_config(spamd_t) +')
policy/modules/services/squid.te +2 -2
@@ -28,9 +28,9 @@ # Local policy # -allow squid_t self:capability { setgid setuid dac_override }; +allow squid_t self:capability { setgid setuid dac_override sys_resource }; dontaudit squid_t self:capability sys_tty_config; -allow squid_t self:process ~{ ptrace setcurrent setexec setfscreate setrlimit execmem execstack execheap }; +allow squid_t self:process ~{ ptrace setcurrent setexec setfscreate execmem execstack execheap }; allow squid_t self:fifo_file rw_file_perms; allow squid_t self:sock_file r_file_perms; allow squid_t self:fd use;
policy/modules/services/stunnel.te +4 -0
@@ -105,6 +105,10 @@ ') optional_policy(` + mount_send_nfs_client_request(stunnel_t) + ') + + optional_policy(` seutil_sigchld_newrole(stunnel_t) ')
policy/modules/services/xserver.if +48 -2
68 lines not on this page · raw message
policy/modules/services/xserver.te +7 -3
@@ -81,7 +81,7 @@ # allow xdm_t self:capability { setgid setuid sys_resource kill sys_tty_config mknod chown dac_override dac_read_search fowner fsetid ipc_owner sys_nice sys_rawio net_bind_service }; -allow xdm_t self:process { setexec setpgid setsched setrlimit signal_perms setkeycreate }; +allow xdm_t self:process { setexec setpgid getsched setsched setrlimit signal_perms setkeycreate }; allow xdm_t self:fifo_file rw_file_perms; allow xdm_t self:shm create_shm_perms; allow xdm_t self:sem create_sem_perms;
@@ -89,7 +89,9 @@ allow xdm_t self:unix_dgram_socket create_socket_perms; allow xdm_t self:tcp_socket create_stream_socket_perms; allow xdm_t self:udp_socket create_socket_perms; -allow xdm_t self:key write; +allow xdm_t self:socket create_socket_perms; +allow xdm_t self:appletalk_socket create_socket_perms; +allow xdm_t self:key { search write }; # Supress permission check on .ICE-unix dontaudit xdm_t ice_tmp_t:dir { getattr setattr };
@@ -106,6 +108,7 @@ kernel_read_system_state(xdm_t) kernel_read_kernel_sysctls(xdm_t) +kernel_read_network_state(xdm_t) corecmd_exec_shell(xdm_t) corecmd_exec_bin(xdm_t)
@@ -154,6 +157,7 @@ domain_dontaudit_read_all_domains_state(xdm_t) files_read_etc_files(xdm_t) +files_read_var_files(xdm_t) files_read_etc_runtime_files(xdm_t) files_exec_etc_files(xdm_t) files_list_mnt(xdm_t)
@@ -257,7 +261,7 @@ allow xdm_t xdm_xserver_tmp_t:sock_file unlink; allow xdm_t xdm_xserver_tmp_t:file unlink; - allow xdm_t xserver_log_t:dir { rw_dir_perms setattr }; + allow xdm_t xserver_log_t:dir { create_dir_perms setattr }; allow xdm_t xserver_log_t:file manage_file_perms; allow xdm_t xserver_log_t:fifo_file manage_file_perms; logging_log_filetrans(xdm_t,xserver_log_t,file)
policy/modules/system/hostname.te +7 -3
@@ -8,7 +8,10 @@ type hostname_t; type hostname_exec_t; -init_system_domain(hostname_t,hostname_exec_t) + +#dont transition from initrc +domain_type(hostname_t) +domain_entry_file(hostname_t,hostname_exec_t) role system_r types hostname_t; ########################################
@@ -56,6 +59,7 @@ sysnet_read_config(hostname_t) sysnet_dns_name_resolve(hostname_t) - - +optional_policy(` + xen_dontaudit_use_fds(hostname_t) +')
policy/modules/system/init.if +0 -7
@@ -158,13 +158,6 @@ allow $1 initrc_t:fifo_file rw_file_perms; allow $1 initrc_t:process sigchld; - ifdef(`hide_broken_symptoms',` - # RHEL4 systems seem to have a stray - # fds open from the initrd - ifdef(`distro_rhel4',` - kernel_dontaudit_use_fds($1) - ') - ') ') ########################################
policy/modules/system/libraries.fc +1 -1
@@ -200,7 +200,7 @@ /usr/lib(64)?/libpostproc\.so.* -- gen_context(system_u:object_r:textrel_shlib_t,s0) /usr/lib(64)?/libavformat.*\.so(\.[^/]*)* -- gen_context(system_u:object_r:textrel_shlib_t,s0) /usr/lib(64)?/libavcodec-.*\.so(\.[^/]*)* -- gen_context(system_u:object_r:textrel_shlib_t,s0) -/usr/lib(64)?/libavutil-.*\.so(\.[^/]*)* -- gen_context(system_u:object_r:textrel_shlib_t,s0) +/usr/lib(64)?/libavutil.*\.so(\.[^/]*)* -- gen_context(system_u:object_r:textrel_shlib_t,s0) /usr/lib(64)?/libxvidcore\.so.* -- gen_context(system_u:object_r:textrel_shlib_t,s0) /usr/lib(64)?/xine/plugins/.+\.so -- gen_context(system_u:object_r:textrel_shlib_t,s0) /usr/lib(64)?/libgsm\.so.* -- gen_context(system_u:object_r:textrel_shlib_t,s0)
policy/modules/system/locallogin.te +3 -1
@@ -47,7 +47,7 @@ allow local_login_t self:sem create_sem_perms; allow local_login_t self:msgq create_msgq_perms; allow local_login_t self:msg { send receive }; -allow local_login_t self:key write; +allow local_login_t self:key { search write }; allow local_login_t local_login_lock_t:file create_file_perms; files_lock_filetrans(local_login_t,local_login_lock_t,file)
@@ -58,6 +58,8 @@ kernel_read_system_state(local_login_t) kernel_read_kernel_sysctls(local_login_t) +kernel_search_key(local_login_t) +kernel_link_key(local_login_t) dev_setattr_mouse_dev(local_login_t) dev_getattr_mouse_dev(local_login_t)
policy/modules/system/logging.fc +3 -0
@@ -38,3 +38,6 @@ /var/spool/postfix/pid -d gen_context(system_u:object_r:var_run_t,s0) /var/tinydns/log/main(/.*)? gen_context(system_u:object_r:var_log_t,s0) + +/var/run/auditd\.pid -- gen_context(system_u:object_r:auditd_var_run_t,s0) +/var/run/auditd_sock -s gen_context(system_u:object_r:auditd_var_run_t,s0)
policy/modules/system/logging.te +2 -1
@@ -120,9 +120,10 @@ allow auditd_t auditd_log_t:lnk_file create_lnk_perms; allow auditd_t var_log_t:dir search; +allow auditd_t auditd_var_run_t:sock_file create_file_perms; allow auditd_t auditd_var_run_t:file create_file_perms; allow auditd_t auditd_var_run_t:dir rw_dir_perms; -files_pid_filetrans(auditd_t,auditd_var_run_t,file) +files_pid_filetrans(auditd_t,auditd_var_run_t,{ file sock_file }) kernel_read_kernel_sysctls(auditd_t) # Needs to be able to run dispatcher. see /etc/audit/auditd.conf
policy/modules/system/miscfiles.fc +1 -0
@@ -9,6 +9,7 @@ # /etc # /etc/localtime -- gen_context(system_u:object_r:locale_t,s0) +/etc/avahi/etc/localtime -- gen_context(system_u:object_r:locale_t,s0) /etc/pki(/.*)? gen_context(system_u:object_r:cert_t,s0) #
policy/modules/system/mount.te +2 -0
@@ -97,6 +97,8 @@ sysnet_use_portmap(mount_t) +selinux_get_enforce_mode(mount_t) + userdom_use_all_users_fds(mount_t) ifdef(`distro_redhat',`
policy/modules/system/selinuxutil.te +6 -0
@@ -355,6 +355,8 @@ kernel_relabelfrom_unlabeled_symlinks(restorecon_t) kernel_relabelfrom_unlabeled_pipes(restorecon_t) kernel_relabelfrom_unlabeled_sockets(restorecon_t) +kernel_dontaudit_list_all_proc(restorecon_t) +kernel_dontaudit_list_sysctls(restorecon_t) dev_relabel_all_dev_nodes(restorecon_t) # cjp: why is this needed?
@@ -613,6 +615,10 @@ userdom_read_generic_user_home_content_files(semanage_t) ') +ifdef(`enable_mls',` + userdom_read_user_tmp_files(secadm, semanage_t) +') + optional_policy(` nscd_socket_use(semanage_t) ')
policy/modules/system/unconfined.if +1 -0
@@ -20,6 +20,7 @@ # Use any Linux capability. allow $1 self:capability *; allow $1 self:fifo_file create_file_perms; + allow $1 self:key *; # Transition to myself, to make get_ordered_context_list happy. allow $1 self:process transition;
policy/modules/system/unconfined.te +5 -0
@@ -195,4 +195,9 @@ ifdef(`targeted_policy',` allow unconfined_execmem_t self:process { execstack execmem }; unconfined_domain_noaudit(unconfined_execmem_t) + optional_policy(` + init_dbus_chat_script(unconfined_execmem_t) + dbus_stub(unconfined_execmem_t) + unconfined_dbus_chat(unconfined_execmem_t) + ') ')
policy/modules/system/userdomain.if +157 -74
384 lines not on this page · raw message
policy/modules/system/userdomain.te +23 -27
102 lines not on this page · raw message
policy/modules/system/xen.if +38 -0
@@ -127,3 +127,41 @@ allow xm_t $1:fifo_file rw_file_perms; allow xm_t $1:process sigchld; ') + + +######################################## +## <summary> +## Inherit and use xen file descriptors. +## </summary> +## <param name="domain"> +## <summary> +## Domain to not audit. +## </summary> +## </param> +# +interface(`xen_use_fds',` + gen_require(` + type xen_t; + ') + + allow $1 xen_t:fd use; +') + +######################################## +## <summary> +## Do not audit attempts to inherit +## xen file descriptors. +## </summary> +## <param name="domain"> +## <summary> +## Domain to not audit. +## </summary> +## </param> +# +interface(`xen_dontaudit_use_fds',` + gen_require(` + type xen_t; + ') + + dontaudit $1 xen_t:fd use; +')
policy/modules/system/xen.te +12 -2
@@ -70,6 +70,8 @@ allow xend_t self:capability { dac_override ipc_lock net_admin setuid sys_nice sys_tty_config net_raw }; allow xend_t self:process { signal sigkill }; +dontaudit xend_t self:process ptrace; + # internal communication is often done using fifo and unix sockets. allow xend_t self:fifo_file rw_file_perms; allow xend_t self:unix_stream_socket create_stream_socket_perms;
@@ -130,6 +132,8 @@ corenet_tcp_bind_soundd_port(xend_t) corenet_sendrecv_xen_server_packets(xend_t) corenet_sendrecv_soundd_server_packets(xend_t) +corenet_tcp_bind_generic_port(xend_t) +corenet_rw_tun_tap_dev(xend_t) dev_read_urand(xend_t) dev_manage_xen(xend_t)
@@ -144,13 +148,17 @@ files_read_kernel_img(xend_t) files_manage_etc_runtime_files(xend_t) files_etc_filetrans_etc_runtime(xend_t,file) +files_read_usr_files(xend_t) storage_raw_read_fixed_disk(xend_t) term_dontaudit_getattr_all_user_ptys(xend_t) term_dontaudit_use_generic_ptys(xend_t) +term_use_ptmx(xend_t) +term_getattr_ptys_fs(xend_t) init_use_fds(xend_t) +init_use_script_ptys(xend_t) libs_use_ld_so(xend_t) libs_use_shared_libs(xend_t)
@@ -200,6 +208,7 @@ term_use_console(xenconsoled_t) init_use_fds(xenconsoled_t) +init_use_script_ptys(xenconsoled_t) libs_use_ld_so(xenconsoled_t) libs_use_shared_libs(xenconsoled_t)
@@ -238,10 +247,11 @@ dev_filetrans_xen(xenstored_t) dev_rw_xen(xenstored_t) -term_dontaudit_use_generic_ptys(xenstored_t) -term_dontaudit_use_console(xenconsoled_t) +term_use_generic_ptys(xenstored_t) +term_use_console(xenconsoled_t) init_use_fds(xenstored_t) +init_use_script_ptys(xenstored_t) libs_use_ld_so(xenstored_t) libs_use_shared_libs(xenstored_t)