+## Allow nfs servers to modify public files +## used for public file transfer services. +##
+#### Allow rsync to modify public files ## used for public file transfer services. ##
diff --git a/refpolicy/policy/modules/admin/consoletype.te b/refpolicy/policy/modules/admin/consoletype.te index 6e1250e..84a5306 100644 --- a/refpolicy/policy/modules/admin/consoletype.te +++ b/refpolicy/policy/modules/admin/consoletype.te @@ -1,5 +1,5 @@ -policy_module(consoletype,1.0.0) +policy_module(consoletype,1.0.1) ######################################## # @@ -107,3 +107,10 @@ optional_policy(` optional_policy(` userdom_use_unpriv_users_fds(consoletype_t) ') + +optional_policy(` + kernel_read_xen_state(consoletype_t) + kernel_write_xen_state(consoletype_t) + xen_append_log(consoletype_t) + xen_dontaudit_rw_unix_stream_sockets(consoletype_t) +') diff --git a/refpolicy/policy/modules/admin/prelink.te b/refpolicy/policy/modules/admin/prelink.te index 3ec1132..f8bc84d 100644 --- a/refpolicy/policy/modules/admin/prelink.te +++ b/refpolicy/policy/modules/admin/prelink.te @@ -1,5 +1,5 @@ -policy_module(prelink,1.1.1) +policy_module(prelink,1.1.2) ######################################## # @@ -10,6 +10,7 @@ attribute prelink_object; type prelink_t; type prelink_exec_t; init_system_domain(prelink_t,prelink_exec_t) +domain_obj_id_change_exemption(prelink_t) type prelink_cache_t; files_type(prelink_cache_t) diff --git a/refpolicy/policy/modules/kernel/mls.te b/refpolicy/policy/modules/kernel/mls.te index f2ea7e1..819a2df 100644 --- a/refpolicy/policy/modules/kernel/mls.te +++ b/refpolicy/policy/modules/kernel/mls.te @@ -1,5 +1,5 @@ -policy_module(mls,1.3.0) +policy_module(mls,1.3.1) ######################################## # @@ -57,6 +57,7 @@ attribute mlsrangetrans; # type lvm_exec_t; +type run_init_t; type setrans_exec_t; ifdef(`enable_mls',` @@ -64,4 +65,5 @@ range_transition initrc_t auditd_exec_t s15:c0.c255; range_transition kernel_t init_exec_t s0 - s15:c0.c255; range_transition kernel_t lvm_exec_t s0 - s15:c0.c255; range_transition initrc_t setrans_exec_t s15:c0.c255; +range_transition run_init_t initrc_exec_t s0 - s15:c0.c255; ') diff --git a/refpolicy/policy/modules/kernel/terminal.if b/refpolicy/policy/modules/kernel/terminal.if index f21191a..04b2dc2 100644 --- a/refpolicy/policy/modules/kernel/terminal.if +++ b/refpolicy/policy/modules/kernel/terminal.if @@ -430,7 +430,7 @@ interface(`term_dontaudit_use_generic_ptys',` type devpts_t; ') - dontaudit $1 devpts_t:chr_file { getattr read write }; + dontaudit $1 devpts_t:chr_file { getattr read write ioctl }; ') ######################################## diff --git a/refpolicy/policy/modules/kernel/terminal.te b/refpolicy/policy/modules/kernel/terminal.te index dde69ea..9fa8156 100644 --- a/refpolicy/policy/modules/kernel/terminal.te +++ b/refpolicy/policy/modules/kernel/terminal.te @@ -1,5 +1,5 @@ -policy_module(terminal,1.1.1) +policy_module(terminal,1.1.2) ######################################## # diff --git a/refpolicy/policy/modules/services/amavis.fc b/refpolicy/policy/modules/services/amavis.fc index b9b789d..96f2fcd 100644 --- a/refpolicy/policy/modules/services/amavis.fc +++ b/refpolicy/policy/modules/services/amavis.fc @@ -8,4 +8,5 @@ /var/lib/amavis(/.*)? gen_context(system_u:object_r:amavis_var_lib_t,s0) /var/log/amavisd\.log -- gen_context(system_u:object_r:amavis_var_log_t,s0) /var/run/amavis(/.*)? gen_context(system_u:object_r:amavis_var_run_t,s0) +/var/spool/amavisd(/.*)? gen_context(system_u:object_r:amavis_spool_t,s0) /var/virusmails(/.*)? gen_context(system_u:object_r:amavis_quarantine_t,s0) diff --git a/refpolicy/policy/modules/services/amavis.te b/refpolicy/policy/modules/services/amavis.te index 34313e2..918fa7e 100644 --- a/refpolicy/policy/modules/services/amavis.te +++ b/refpolicy/policy/modules/services/amavis.te @@ -1,5 +1,5 @@ -policy_module(amavis,1.0.3) +policy_module(amavis,1.0.4) ######################################## # @@ -35,12 +35,15 @@ files_tmp_file(amavis_tmp_t) type amavis_quarantine_t; files_type(amavis_quarantine_t) +type amavis_spool_t; +files_type(amavis_spool_t) + ######################################## # # amavis local policy # -allow amavis_t self:capability { chown dac_override setgid setuid }; +allow amavis_t self:capability { kill chown dac_override setgid setuid }; dontaudit amavis_t self:capability sys_tty_config; allow amavis_t self:process { signal sigchld signull }; allow amavis_t self:fifo_file rw_file_perms; @@ -58,6 +61,11 @@ allow amavis_t amavis_quarantine_t:file create_file_perms; allow amavis_t amavis_quarantine_t:sock_file create_file_perms; allow amavis_t amavis_quarantine_t:dir create_dir_perms; +# Spool Files +allow amavis_t amavis_spool_t:dir manage_dir_perms; +allow amavis_t amavis_spool_t:file manage_file_perms; +files_spool_filetrans(amavis_t,amavis_spool_t,{ dir file }) + # tmp files allow amavis_t amavis_tmp_t:file create_file_perms; allow amavis_t amavis_tmp_t:dir { rw_dir_perms setattr }; @@ -82,8 +90,10 @@ allow amavis_t amavis_var_run_t:sock_file manage_file_perms; allow amavis_t amavis_var_run_t:dir rw_dir_perms; files_pid_filetrans(amavis_t,amavis_var_run_t, { file sock_file }) +kernel_read_kernel_sysctls(amavis_t) # amavis tries to access /proc/self/stat, /etc/shadow and /root - perl... kernel_dontaudit_list_proc(amavis_t) +kernel_dontaudit_read_system_state(amavis_t) # find perl corecmd_exec_bin(amavis_t) @@ -115,6 +125,7 @@ auth_dontaudit_read_shadow(amavis_t) init_use_fds(amavis_t) init_use_script_ptys(amavis_t) +init_stream_connect_script(amavis_t) libs_use_ld_so(amavis_t) libs_use_shared_libs(amavis_t) @@ -134,8 +145,13 @@ cron_rw_pipes(amavis_t) mta_read_config(amavis_t) +ifdef(`targeted_policy',` + term_dontaudit_use_generic_ptys(amavis_t) +') + optional_policy(` clamav_stream_connect(amavis_t) + clamav_domtrans_clamscan(amavis_t) ') optional_policy(` diff --git a/refpolicy/policy/modules/services/bind.te b/refpolicy/policy/modules/services/bind.te index ba9721d..15cd2e7 100644 --- a/refpolicy/policy/modules/services/bind.te +++ b/refpolicy/policy/modules/services/bind.te @@ -1,5 +1,5 @@ -policy_module(bind,1.1.3) +policy_module(bind,1.1.4) ######################################## # @@ -123,6 +123,8 @@ term_dontaudit_use_console(named_t) corecmd_search_sbin(named_t) +dev_read_urand(named_t) + domain_use_interactive_fds(named_t) files_read_etc_files(named_t) @@ -137,6 +139,7 @@ libs_use_shared_libs(named_t) logging_send_syslog_msg(named_t) miscfiles_read_localization(named_t) +miscfiles_read_certs(named_t) sysnet_read_config(named_t) diff --git a/refpolicy/policy/modules/services/bluetooth.te b/refpolicy/policy/modules/services/bluetooth.te index 2cac58b..1950541 100644 --- a/refpolicy/policy/modules/services/bluetooth.te +++ b/refpolicy/policy/modules/services/bluetooth.te @@ -1,5 +1,5 @@ -policy_module(bluetooth,1.2.4) +policy_module(bluetooth,1.2.5) ######################################## # @@ -211,6 +211,7 @@ sysnet_read_config(bluetooth_helper_t) ifdef(`targeted_policy',` files_rw_generic_tmp_sockets(bluetooth_helper_t) + files_manage_generic_tmp_files(bluetooth_helper_t) fs_rw_tmpfs_files(bluetooth_helper_t) @@ -218,7 +219,7 @@ ifdef(`targeted_policy',` unconfined_stream_connect(bluetooth_helper_t) - userdom_read_all_users_home_content_files(bluetooth_helper_t) + userdom_manage_generic_user_home_content_files(bluetooth_helper_t) optional_policy(` xserver_stream_connect_xdm(bluetooth_helper_t) diff --git a/refpolicy/policy/modules/services/cups.te b/refpolicy/policy/modules/services/cups.te index 7c3fbcb..37c3f43 100644 --- a/refpolicy/policy/modules/services/cups.te +++ b/refpolicy/policy/modules/services/cups.te @@ -1,5 +1,5 @@ -policy_module(cups,1.3.3) +policy_module(cups,1.3.4) ######################################## # @@ -672,6 +672,7 @@ allow cupsd_lpd_t self:process signal_perms; allow cupsd_lpd_t self:fifo_file rw_file_perms; allow cupsd_lpd_t self:tcp_socket connected_stream_socket_perms; allow cupsd_lpd_t self:udp_socket create_socket_perms; +allow cupsd_lpd_t self:netlink_route_socket r_netlink_socket_perms; # for identd # cjp: this should probably only be inetd_child rules? @@ -731,6 +732,8 @@ miscfiles_read_localization(cupsd_lpd_t) sysnet_read_config(cupsd_lpd_t) +cups_stream_connect(cupsd_lpd_t) + optional_policy(` inetd_service_domain(cupsd_lpd_t,cupsd_lpd_exec_t) ') diff --git a/refpolicy/policy/modules/services/hal.te b/refpolicy/policy/modules/services/hal.te index dc4af08..499e339 100644 --- a/refpolicy/policy/modules/services/hal.te +++ b/refpolicy/policy/modules/services/hal.te @@ -1,5 +1,5 @@ -policy_module(hal,1.3.6) +policy_module(hal,1.3.7) ######################################## # @@ -93,6 +93,7 @@ files_read_usr_files(hald_t) # hal is now execing pm-suspend files_create_boot_flag(hald_t) files_getattr_all_dirs(hald_t) +files_read_kernel_img(hald_t) fs_getattr_all_fs(hald_t) fs_search_all(hald_t) diff --git a/refpolicy/policy/modules/services/pyzor.fc b/refpolicy/policy/modules/services/pyzor.fc index 1b6d31e..71e71c8 100644 --- a/refpolicy/policy/modules/services/pyzor.fc +++ b/refpolicy/policy/modules/services/pyzor.fc @@ -5,3 +5,7 @@ /var/lib/pyzord(/.*)? gen_context(system_u:object_r:pyzor_var_lib_t,s0) /var/log/pyzord.log -- gen_context(system_u:object_r:pyzord_log_t,s0) + +ifdef(`strict_policy',` +HOME_DIR/\.pyzor(/.*)? gen_context(system_u:object_r:ROLE_pyzor_home_t,s0) +') diff --git a/refpolicy/policy/modules/services/pyzor.te b/refpolicy/policy/modules/services/pyzor.te index ab12af3..1bfd609 100644 --- a/refpolicy/policy/modules/services/pyzor.te +++ b/refpolicy/policy/modules/services/pyzor.te @@ -1,5 +1,5 @@ -policy_module(pyzor,1.0.0) +policy_module(pyzor,1.0.1) ######################################## # diff --git a/refpolicy/policy/modules/services/rpc.te b/refpolicy/policy/modules/services/rpc.te index 9c03855..f8403b7 100644 --- a/refpolicy/policy/modules/services/rpc.te +++ b/refpolicy/policy/modules/services/rpc.te @@ -1,5 +1,5 @@ -policy_module(rpc,1.2.3) +policy_module(rpc,1.2.4) ######################################## # @@ -111,9 +111,17 @@ files_getattr_tmp_dirs(nfsd_t) # cjp: this should really have its own type files_manage_mounttab(rpcd_t) +# Read access to public_content_t and public_content_rw_t +miscfiles_read_public_files(nfsd_t) + portmap_tcp_connect(nfsd_t) portmap_udp_chat(nfsd_t) +# Write access to public_content_t and public_content_rw_t +tunable_policy(`allow_nfsd_anon_write',` + miscfiles_manage_public_files(nfsd_t) +') + tunable_policy(`nfs_export_all_rw',` fs_read_noxattr_fs_files(nfsd_t) auth_manage_all_files_except_shadow(nfsd_t) diff --git a/refpolicy/policy/modules/services/xfs.if b/refpolicy/policy/modules/services/xfs.if index 92ec773..d8bf4d1 100644 --- a/refpolicy/policy/modules/services/xfs.if +++ b/refpolicy/policy/modules/services/xfs.if @@ -41,3 +41,23 @@ interface(`xfs_stream_connect',` allow $1 xfs_tmp_t:sock_file write; allow $1 xfs_t:unix_stream_socket connectto; ') + + +######################################## +##