Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# Network Interface generated macros 
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
define(`create_netif_interfaces',``
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive TCP network traffic on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_tcp_sendrecv_$1',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_netif_t;
Chris PeBenito bc1fba
		class netif { tcp_send tcp_recv };
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_netif_t:netif { tcp_send tcp_recv };
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send UDP network traffic on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_send_$1',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_netif_t;
Chris PeBenito bc1fba
		class netif udp_send;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_netif_t:netif udp_send;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Receive UDP network traffic on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="read" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_receive_$1',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_netif_t;
Chris PeBenito bc1fba
		class netif udp_recv;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_netif_t:netif udp_recv;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive UDP network traffic on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_sendrecv_$1',`
Chris PeBenito f2e4ab
	corenet_udp_send_$1(dollarsone)
Chris PeBenito f2e4ab
	corenet_udp_receive_$1(dollarsone)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send raw IP packets on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_send_$1',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_netif_t;
Chris PeBenito bc1fba
		class netif rawip_send;
Chris PeBenito bc1fba
		class capability net_raw;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_netif_t:netif rawip_send;
Chris PeBenito f2e4ab
	allow dollarsone self:capability net_raw;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Receive raw IP packets on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="read" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_receive_$1',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_netif_t;
Chris PeBenito bc1fba
		class netif rawip_recv;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_netif_t:netif rawip_recv;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive raw IP packets on the $1 interface.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_sendrecv_$1',`
Chris PeBenito f2e4ab
	corenet_raw_send_$1(dollarsone)
Chris PeBenito f2e4ab
	corenet_raw_receive_$1(dollarsone)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
'') dnl end create_netif_interfaces
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# Network node generated macros 
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
define(`create_node_interfaces',``
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive TCP traffic on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_tcp_sendrecv_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class node { tcp_send tcp_recv };
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:node { tcp_send tcp_recv };
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send UDP traffic on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_send_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class node udp_send;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:node udp_send;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Receive UDP traffic on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="read" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_receive_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class node udp_recv;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:node udp_recv;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive UDP traffic on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_sendrecv_$1_node',`
Chris PeBenito f2e4ab
	corenet_udp_send_$1_node(dollarsone)
Chris PeBenito f2e4ab
	corenet_udp_receive_$1_node(dollarsone)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send raw IP packets on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_send_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class node rawip_send;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:node rawip_send;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Receive raw IP packets on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_receive_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class node rawip_recv;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:node rawip_recv;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive raw IP packets on the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_raw_sendrecv_$1_node',`
Chris PeBenito f2e4ab
	corenet_raw_send_$1_node(dollarsone)
Chris PeBenito f2e4ab
	corenet_raw_receive_$1_node(dollarsone)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Bind TCP sockets to node $1.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="none"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_tcp_bind_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class tcp_socket node_bind;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:tcp_socket node_bind;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Bind UDP sockets to the $1 node.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="none"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_bind_$1_node',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_node_t;
Chris PeBenito bc1fba
		class udp_socket node_bind;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_node_t:udp_socket node_bind;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
'') dnl end create_node_interfaces
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# Network port generated macros 
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
########################################
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
define(`create_port_interfaces',``
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive TCP traffic on the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_tcp_sendrecv_$1_port',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_port_t;
Chris PeBenito bc1fba
		class tcp_socket { send_msg recv_msg };
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_port_t:tcp_socket { send_msg recv_msg };
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send UDP traffic on the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="write" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_send_$1_port',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_port_t;
Chris PeBenito bc1fba
		class udp_socket send_msg;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_port_t:udp_socket send_msg;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Receive UDP traffic on the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="read" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_receive_$1_port',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_port_t;
Chris PeBenito bc1fba
		class udp_socket recv_msg;
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_port_t:udp_socket recv_msg;
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Send and receive UDP traffic on the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="both" weight="10"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_sendrecv_$1_port',`
Chris PeBenito f2e4ab
	corenet_udp_send_$1_port(dollarsone)
Chris PeBenito f2e4ab
	corenet_udp_receive_$1_port(dollarsone)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Bind TCP sockets to the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="none"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_tcp_bind_$1_port',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_port_t;
Chris PeBenito bc1fba
		class tcp_socket name_bind;
Chris PeBenito bc1fba
		$3
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
	allow dollarsone $1_port_t:tcp_socket name_bind;
Chris PeBenito f2e4ab
	$2
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
########################################
Chris PeBenito 414e41
## <desc>
Chris PeBenito 414e41
##	Bind UDP sockets to the $1 port.
Chris PeBenito 414e41
## </desc>
Chris PeBenito 414e41
## <param name="domain">
Chris PeBenito 414e41
##	The type of the process performing this action.
Chris PeBenito 414e41
## </param>
Chris PeBenito 414e41
## <infoflow type="none"/>
Chris PeBenito f2e4ab
#
Chris PeBenito 199895
interface(`corenet_udp_bind_$1_port',`
Chris PeBenito bc1fba
	gen_require(`
Chris PeBenito bc1fba
		type $1_port_t;
Chris PeBenito bc1fba
		class udp_socket name_bind;
Chris PeBenito bc1fba
		$3
Chris PeBenito bc1fba
	')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
	allow dollarsone $1_port_t:udp_socket name_bind;
Chris PeBenito f2e4ab
	$2
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
'') dnl end create_port_interfaces
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# network_interface(linux_interfacename,mls_sensitivity)
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
define(`network_interface',`
Chris PeBenito f2e4ab
create_netif_interfaces($1)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# network_node(node_name,mls_sensitivity,address,netmask)
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
define(`network_node',`
Chris PeBenito f2e4ab
create_node_interfaces($1)
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
# These next three macros have formatting, and should not me indented
Chris PeBenito f2e4ab
define(`determine_reserved_capability',`dnl
Chris PeBenito f2e4ab
ifelse(eval($2 < 1024),1,``allow' dollarsone self:capability net_bind_service;',`dnl
Chris PeBenito f2e4ab
ifelse($4,`',`',`determine_reserved_capability(shiftn(3,$*))')dnl end inner ifelse
Chris PeBenito f2e4ab
')dnl end outer ifelse
Chris PeBenito f2e4ab
') dnl end determine reserved capability
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
define(`determine_reserved_capability_depend',`dnl
Chris PeBenito f2e4ab
ifelse(eval($2 < 1024),1,`class capability net_bind_service;',`dnl
Chris PeBenito f2e4ab
ifelse($4,`',`',`determine_reserved_capability_depend(shiftn(3,$*))')dnl end inner ifelse
Chris PeBenito f2e4ab
')dnl end outer ifelse
Chris PeBenito f2e4ab
') dnl end determine reserved capability depend
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
define(`declare_ports',`dnl
Chris PeBenito f2e4ab
ifelse(eval($3 < 1024),1,`typeattribute $1 reserved_port_type;',`dnl')
Chris PeBenito f2e4ab
portcon $2 $3 context_template(system_u:object_r:$1,$4)
Chris PeBenito f2e4ab
ifelse(`$5',`',`',`declare_ports($1,shiftn(4,$*))')dnl
Chris PeBenito f2e4ab
')
Chris PeBenito f2e4ab
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
# network_port(port_name,protocol portnum mls_sensitivity [,protocol portnum mls_sensitivity[,...]])
Chris PeBenito f2e4ab
#
Chris PeBenito f2e4ab
define(`network_port',`
Chris PeBenito f2e4ab
create_port_interfaces($1,determine_reserved_capability(shift($*)),determine_reserved_capability_depend(shift($*)))
Chris PeBenito f2e4ab
')