add ddclient, bug 1523
This commit is contained in:
parent
5b4d0991b4
commit
70b8a7231e
@ -43,6 +43,7 @@
|
|||||||
clamav (Erich Schubert)
|
clamav (Erich Schubert)
|
||||||
courier
|
courier
|
||||||
dante
|
dante
|
||||||
|
ddclient
|
||||||
dpkg (Erich Schubert)
|
dpkg (Erich Schubert)
|
||||||
dnsmasq
|
dnsmasq
|
||||||
ethereal
|
ethereal
|
||||||
|
11
refpolicy/policy/modules/services/ddclient.fc
Normal file
11
refpolicy/policy/modules/services/ddclient.fc
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
/etc/ddclient\.conf -- gen_context(system_u:object_r:ddclient_etc_t,s0)
|
||||||
|
/etc/ddtcd\.conf -- gen_context(system_u:object_r:ddclient_etc_t,s0)
|
||||||
|
|
||||||
|
/usr/sbin/ddclient -- gen_context(system_u:object_r:ddclient_exec_t,s0)
|
||||||
|
/usr/sbin/ddtcd -- gen_context(system_u:object_r:ddclient_exec_t,s0)
|
||||||
|
|
||||||
|
/var/cache/ddclient(/.*)? gen_context(system_u:object_r:ddclient_var_t,s0)
|
||||||
|
/var/lib/ddt-client(/.*)? gen_context(system_u:object_r:ddclient_var_lib_t,s0)
|
||||||
|
/var/log/ddtcd\.log.* -- gen_context(system_u:object_r:ddclient_log_t,s0)
|
||||||
|
/var/run/ddclient\.pid -- gen_context(system_u:object_r:ddclient_var_run_t,s0)
|
||||||
|
/var/run/ddtcd\.pid -- gen_context(system_u:object_r:ddclient_var_run_t,s0)
|
25
refpolicy/policy/modules/services/ddclient.if
Normal file
25
refpolicy/policy/modules/services/ddclient.if
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
## <summary>Update dynamic IP address at DynDNS.org</summary>
|
||||||
|
|
||||||
|
#######################################
|
||||||
|
## <summary>
|
||||||
|
## Execute ddclient in the ddclient domain.
|
||||||
|
## </summary>
|
||||||
|
## <param name="domain">
|
||||||
|
## <summary>
|
||||||
|
## Domain allowed access.
|
||||||
|
## </summary>
|
||||||
|
## </param>
|
||||||
|
#
|
||||||
|
interface(`ddclient_domtrans',`
|
||||||
|
gen_require(`
|
||||||
|
type ddclient_t, ddclient_exec_t;
|
||||||
|
')
|
||||||
|
|
||||||
|
corecmd_search_sbin($1)
|
||||||
|
domain_auto_trans($1, ddclient_exec_t, ddclient_t)
|
||||||
|
|
||||||
|
allow $1 ddclient_t:fd use;
|
||||||
|
allow ddclient_t $1:fd use;
|
||||||
|
allow ddclient_t $1:fifo_file rw_file_perms;
|
||||||
|
allow ddclient_t $1:process sigchld;
|
||||||
|
')
|
124
refpolicy/policy/modules/services/ddclient.te
Normal file
124
refpolicy/policy/modules/services/ddclient.te
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
|
||||||
|
policy_module(ddclient,1.0.0)
|
||||||
|
|
||||||
|
########################################
|
||||||
|
#
|
||||||
|
# Declarations
|
||||||
|
#
|
||||||
|
|
||||||
|
type ddclient_t;
|
||||||
|
type ddclient_exec_t;
|
||||||
|
init_daemon_domain(ddclient_t,ddclient_exec_t)
|
||||||
|
|
||||||
|
type ddclient_etc_t;
|
||||||
|
files_type(ddclient_etc_t)
|
||||||
|
|
||||||
|
type ddclient_log_t;
|
||||||
|
logging_log_file(ddclient_log_t)
|
||||||
|
|
||||||
|
type ddclient_var_t;
|
||||||
|
files_type(ddclient_var_t)
|
||||||
|
|
||||||
|
type ddclient_var_lib_t;
|
||||||
|
files_type(ddclient_var_lib_t)
|
||||||
|
|
||||||
|
type ddclient_var_run_t;
|
||||||
|
files_pid_file(ddclient_var_run_t)
|
||||||
|
|
||||||
|
########################################
|
||||||
|
#
|
||||||
|
# Declarations
|
||||||
|
#
|
||||||
|
|
||||||
|
dontaudit ddclient_t self:capability sys_tty_config;
|
||||||
|
allow ddclient_t self:process signal_perms;
|
||||||
|
allow ddclient_t self:fifo_file rw_file_perms;
|
||||||
|
allow ddclient_t self:tcp_socket create_socket_perms;
|
||||||
|
allow ddclient_t self:udp_socket create_socket_perms;
|
||||||
|
|
||||||
|
allow ddclient_t ddclient_etc_t:file r_file_perms;
|
||||||
|
|
||||||
|
allow ddclient_t ddclient_log_t:file manage_file_perms;
|
||||||
|
logging_log_filetrans(ddclient_t,ddclient_log_t,file)
|
||||||
|
|
||||||
|
allow ddclient_t ddclient_var_t:dir manage_dir_perms;
|
||||||
|
allow ddclient_t ddclient_var_t:file manage_file_perms;
|
||||||
|
allow ddclient_t ddclient_var_t:lnk_file create_lnk_perms;
|
||||||
|
allow ddclient_t ddclient_var_t:sock_file manage_file_perms;
|
||||||
|
allow ddclient_t ddclient_var_t:fifo_file manage_file_perms;
|
||||||
|
files_var_filetrans(ddclient_t,ddclient_var_t,{ file lnk_file sock_file fifo_file })
|
||||||
|
|
||||||
|
allow ddclient_t ddclient_var_lib_t:file manage_file_perms;
|
||||||
|
allow ddclient_t ddclient_var_lib_t:dir rw_dir_perms;
|
||||||
|
files_var_lib_filetrans(ddclient_t,ddclient_var_lib_t,file)
|
||||||
|
|
||||||
|
allow ddclient_t ddclient_var_run_t:file manage_file_perms;
|
||||||
|
allow ddclient_t ddclient_var_run_t:dir rw_dir_perms;
|
||||||
|
files_pid_filetrans(ddclient_t,ddclient_var_run_t,file)
|
||||||
|
|
||||||
|
kernel_read_system_state(ddclient_t)
|
||||||
|
kernel_read_network_state(ddclient_t)
|
||||||
|
kernel_read_software_raid_state(ddclient_t)
|
||||||
|
kernel_getattr_core_if(ddclient_t)
|
||||||
|
kernel_getattr_message_if(ddclient_t)
|
||||||
|
kernel_read_kernel_sysctls(ddclient_t)
|
||||||
|
|
||||||
|
corecmd_exec_shell(ddclient_t)
|
||||||
|
corecmd_exec_bin(ddclient_t)
|
||||||
|
|
||||||
|
corenet_tcp_sendrecv_generic_if(ddclient_t)
|
||||||
|
corenet_udp_sendrecv_generic_if(ddclient_t)
|
||||||
|
corenet_raw_sendrecv_generic_if(ddclient_t)
|
||||||
|
corenet_tcp_sendrecv_all_nodes(ddclient_t)
|
||||||
|
corenet_udp_sendrecv_all_nodes(ddclient_t)
|
||||||
|
corenet_raw_sendrecv_all_nodes(ddclient_t)
|
||||||
|
corenet_tcp_sendrecv_all_ports(ddclient_t)
|
||||||
|
corenet_udp_sendrecv_all_ports(ddclient_t)
|
||||||
|
corenet_non_ipsec_sendrecv(ddclient_t)
|
||||||
|
corenet_tcp_bind_all_nodes(ddclient_t)
|
||||||
|
corenet_udp_bind_all_nodes(ddclient_t)
|
||||||
|
corenet_tcp_connect_all_ports(ddclient_t)
|
||||||
|
|
||||||
|
dev_read_sysfs(ddclient_t)
|
||||||
|
dev_read_urand(ddclient_t)
|
||||||
|
|
||||||
|
domain_use_interactive_fds(ddclient_t)
|
||||||
|
|
||||||
|
files_read_etc_files(ddclient_t)
|
||||||
|
files_read_etc_runtime_files(ddclient_t)
|
||||||
|
files_read_usr_files(ddclient_t)
|
||||||
|
|
||||||
|
fs_getattr_all_fs(ddclient_t)
|
||||||
|
fs_search_auto_mountpoints(ddclient_t)
|
||||||
|
|
||||||
|
term_dontaudit_use_console(ddclient_t)
|
||||||
|
|
||||||
|
init_use_fds(ddclient_t)
|
||||||
|
init_use_script_ptys(ddclient_t)
|
||||||
|
|
||||||
|
libs_use_ld_so(ddclient_t)
|
||||||
|
libs_use_shared_libs(ddclient_t)
|
||||||
|
|
||||||
|
logging_send_syslog_msg(ddclient_t)
|
||||||
|
|
||||||
|
miscfiles_read_localization(ddclient_t)
|
||||||
|
|
||||||
|
sysnet_exec_ifconfig(ddclient_t)
|
||||||
|
sysnet_read_config(ddclient_t)
|
||||||
|
|
||||||
|
userdom_dontaudit_use_unpriv_user_fds(ddclient_t)
|
||||||
|
userdom_dontaudit_search_sysadm_home_dirs(ddclient_t)
|
||||||
|
|
||||||
|
ifdef(`targeted_policy',`
|
||||||
|
term_dontaudit_use_unallocated_ttys(ddclient_t)
|
||||||
|
term_dontaudit_use_generic_ptys(ddclient_t)
|
||||||
|
files_dontaudit_read_root_files(ddclient_t)
|
||||||
|
')
|
||||||
|
|
||||||
|
optional_policy(`
|
||||||
|
seutil_sigchld_newrole(ddclient_t)
|
||||||
|
')
|
||||||
|
|
||||||
|
optional_policy(`
|
||||||
|
udev_read_db(ddclient_t)
|
||||||
|
')
|
@ -1,5 +1,5 @@
|
|||||||
|
|
||||||
policy_module(ppp,1.2.0)
|
policy_module(ppp,1.2.1)
|
||||||
|
|
||||||
########################################
|
########################################
|
||||||
#
|
#
|
||||||
@ -196,6 +196,10 @@ ifdef(`targeted_policy', `
|
|||||||
')
|
')
|
||||||
')
|
')
|
||||||
|
|
||||||
|
optional_policy(`
|
||||||
|
ddclient_domtrans(pppd_t)
|
||||||
|
')
|
||||||
|
|
||||||
optional_policy(`
|
optional_policy(`
|
||||||
tunable_policy(`pppd_can_insmod && ! secure_mode_insmod',`
|
tunable_policy(`pppd_can_insmod && ! secure_mode_insmod',`
|
||||||
modutils_domtrans_insmod_uncond(pppd_t)
|
modutils_domtrans_insmod_uncond(pppd_t)
|
||||||
|
Loading…
Reference in New Issue
Block a user