|
Chris PeBenito |
e181fe |
# Copyright (C) 2005 Tresys Technology, LLC
|
|
Chris PeBenito |
e181fe |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_general_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 netif_t:netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type netif_t;
|
|
Chris PeBenito |
0e730c |
class netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_general_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_general_interface($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_general_interface($1)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_general_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_raw_on_general_interface($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_raw_on_general_interface($1)
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_general_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_udp_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_t:netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_udp_on_general_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type netif_t;
|
|
Chris PeBenito |
b4cd15 |
class netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_general_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 netif_t:netif udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_interface_depend',`
|
|
Chris PeBenito |
0e730c |
type netif_t;
|
|
Chris PeBenito |
0e730c |
class netif udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_general_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_raw_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_t:netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
allow $1 self:capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_raw_on_general_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type netif_t;
|
|
Chris PeBenito |
b4cd15 |
class netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
class capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_general_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_general_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 netif_t:netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_general_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type netif_t;
|
|
Chris PeBenito |
0e730c |
class netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 netif_type:netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_interfaces_depend',`
|
|
Chris PeBenito |
0e730c |
attribute netif_type;
|
|
Chris PeBenito |
0e730c |
class netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_all_interfaces($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_all_interfaces($1)
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_raw_on_all_interfaces($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_raw_on_all_interfaces($1)
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_udp_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_type:netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_udp_on_all_interfaces_depend',`
|
|
Chris PeBenito |
b4cd15 |
attribute netif_type;
|
|
Chris PeBenito |
b4cd15 |
class netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_raw_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_type:netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
allow $1 self:capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_send_raw_on_all_interfaces_depend',`
|
|
Chris PeBenito |
b4cd15 |
attribute netif_type;
|
|
Chris PeBenito |
b4cd15 |
class netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
class capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_receive_udp_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_type:netif udp_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_receive_udp_on_all_interfaces_depend',`
|
|
Chris PeBenito |
b4cd15 |
attribute netif_type;
|
|
Chris PeBenito |
b4cd15 |
class netif udp_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_all_interfaces(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_receive_raw_on_all_interfaces',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow $1 netif_type:netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
define(`corenetwork_receive_raw_on_all_interfaces_depend',`
|
|
Chris PeBenito |
b4cd15 |
attribute netif_type;
|
|
Chris PeBenito |
b4cd15 |
class netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:node { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class node { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_general_node',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_udp_on_general_node($1,$2)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_udp_on_general_node($1,$2)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_general_node',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_raw_on_general_node($1,$2)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_raw_on_general_node($1,$2)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:node rawip_send;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class node rawip_send;
|
|
Chris PeBenito |
0e730c |
class capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_general_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_t:udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_node_depend',`
|
|
Chris PeBenito |
0e730c |
type node_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:node { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_nodes_depend',`
|
|
Chris PeBenito |
0e730c |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class node { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_all_nodes($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_all_nodes($1)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_all_nodes',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_raw_on_all_nodes($1,optional)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_raw_on_all_nodes($1,optional)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_nodes_depend',`
|
|
Chris PeBenito |
0e730c |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_nodes_depend',`
|
|
Chris PeBenito |
0e730c |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:node rawip_send;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_all_nodes_depend',`
|
|
Chris PeBenito |
0e730c |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class node rawip_send;
|
|
Chris PeBenito |
0e730c |
class capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_all_nodes_depend',`
|
|
Chris PeBenito |
0e730c |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
bd202f |
define(`corenetwork_bind_tcp_on_all_nodes_depend',`
|
|
Chris PeBenito |
219bcf |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_all_nodes(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_nodes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 node_type:udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_nodes_depend',`
|
|
Chris PeBenito |
219bcf |
attribute node_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_t:tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_general_port_depend',`
|
|
Chris PeBenito |
0e730c |
type port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_general_port($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_general_port($1)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_t:udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_general_port_depend',`
|
|
Chris PeBenito |
0e730c |
type port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_t:udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_general_port_depend',`
|
|
Chris PeBenito |
0e730c |
type port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_t:tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_port_depend',`
|
|
Chris PeBenito |
0e730c |
type port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_general_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_t:udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_general_port_depend',`
|
|
Chris PeBenito |
0e730c |
type port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_all_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_type:tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute port_type;
|
|
Chris PeBenito |
0e730c |
class tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_all_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_all_ports($1)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_all_ports($1)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_all_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_type:udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_all_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_type:udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
# corenetwork_bind_tcp_on_all_ports(domain,[`optional'])
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_type:tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
bd202f |
define(`corenetwork_bind_tcp_on_all_ports_depend',`
|
|
Chris PeBenito |
23af43 |
attribute port_type;
|
|
Chris PeBenito |
0e730c |
class tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_all_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 port_type:udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_ports_depend',`
|
|
Chris PeBenito |
23af43 |
attribute port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_reserved_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_t:tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_reserved_port_depend',`
|
|
Chris PeBenito |
0e730c |
type reserved_port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_reserved_port',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_udp_on_reserved_port($1,$2)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_udp_on_reserved_port($1,$2)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_reserved_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_t:udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_reserved_port_depend',`
|
|
Chris PeBenito |
0e730c |
type reserved_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_reserved_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_t:udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_reserved_port_depend',`
|
|
Chris PeBenito |
0e730c |
type reserved_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_reserved_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_t:tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_reserved_port_depend',`
|
|
Chris PeBenito |
0e730c |
type reserved_port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
class capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_reserved_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_reserved_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_t:udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_reserved_port_depend',`
|
|
Chris PeBenito |
0e730c |
type reserved_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
class capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_type:tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute reserved_port_type;
|
|
Chris PeBenito |
0e730c |
class tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_all_reserved_ports',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_udp_on_all_reserved_ports($1,optional)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_udp_on_all_reserved_ports($1,optional)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_type:udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute reserved_port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_type:udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
0e730c |
attribute reserved_port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_type:tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
bd202f |
define(`corenetwork_bind_tcp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
a2d824 |
attribute reserved_port_type;
|
|
Chris PeBenito |
0e730c |
class tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
class capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
b16c6b |
# corenetwork_ignore_bind_tcp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
define(`corenetwork_ignore_bind_tcp_on_all_reserved_ports',`
|
|
Chris PeBenito |
b16c6b |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
dontaudit $1 reserved_port_type:tcp_socket name_bind;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
define(`corenetwork_ignore_bind_tcp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
b16c6b |
attribute reserved_port_type;
|
|
Chris PeBenito |
b16c6b |
class tcp_socket name_bind;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
#######################################
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
0e730c |
allow $1 reserved_port_type:udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
allow $1 self:capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
a2d824 |
attribute reserved_port_type;
|
|
Chris PeBenito |
0e730c |
class udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
class self:capability net_bind_service;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
a2d824 |
#######################################
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_ignore_bind_tcp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
a2d824 |
define(`corenetwork_ignore_bind_tcp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
a2d824 |
dontaudit $1 reserved_port_type:tcp_socket name_bind;
|
|
Chris PeBenito |
a2d824 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
a2d824 |
define(`corenetwork_ignore_bind_udp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
a2d824 |
attribute reserved_port_type;
|
|
Chris PeBenito |
a2d824 |
class tcp_socket name_bind;
|
|
Chris PeBenito |
a2d824 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
a2d824 |
#######################################
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_ignore_bind_udp_on_all_reserved_ports(domain)
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
a2d824 |
define(`corenetwork_ignore_bind_udp_on_all_reserved_ports',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
a2d824 |
dontaudit $1 reserved_port_type:udp_socket name_bind;
|
|
Chris PeBenito |
a2d824 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
a2d824 |
define(`corenetwork_ignore_bind_udp_on_all_reserved_ports_depend',`
|
|
Chris PeBenito |
a2d824 |
attribute reserved_port_type;
|
|
Chris PeBenito |
a2d824 |
class udp_socket name_bind;
|
|
Chris PeBenito |
a2d824 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
# This section is processed through m4 to create real interfaces
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
# dont generate anything but macros on this pass
|
|
Chris PeBenito |
b4cd15 |
ifdef(`interface_pass',`
|
|
Chris PeBenito |
b4cd15 |
define(`allow',`dnl')
|
|
Chris PeBenito |
b4cd15 |
define(`type',`dnl')
|
|
Chris PeBenito |
b4cd15 |
define(`attribute',`dnl')
|
|
Chris PeBenito |
b4cd15 |
define(`portcon',`dnl')
|
|
Chris PeBenito |
b4cd15 |
define(`devices_make_device_node',`dnl')
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
# Network Interface generated macros
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
b4cd15 |
define(`create_netif_interfaces',``
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_$1_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_netif_t:netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type $1_netif_t;
|
|
Chris PeBenito |
0e730c |
class netif { tcp_send tcp_recv };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_$1_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_$1_interface',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_udp_on_$1_interface(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_udp_on_$1_interface(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_$1_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_$1_interface',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_raw_on_$1_interface(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_raw_on_$1_interface(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_$1_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow dollarsone $1_netif_t:netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type $1_netif_t;
|
|
Chris PeBenito |
b4cd15 |
class netif udp_send;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_$1_interface(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_netif_t:netif udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_interface_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_netif_t;
|
|
Chris PeBenito |
0e730c |
class netif udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_$1_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_$1_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
b4cd15 |
allow dollarsone $1_netif_t:netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
allow dollarsone self:capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_$1_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type $1_netif_t;
|
|
Chris PeBenito |
b4cd15 |
class netif rawip_send;
|
|
Chris PeBenito |
b4cd15 |
class capability net_raw;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_$1_interface(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_$1_interface',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_netif_t:netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_$1_interface_depend',`
|
|
Chris PeBenito |
b4cd15 |
type $1_netif_t;
|
|
Chris PeBenito |
0e730c |
class netif rawip_recv;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
0e730c |
'') dnl end create_netif_interfaces
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
# Network node generated macros
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`create_node_interfaces',``
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_$1_node(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:node { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class node { tcp_send tcp_recv };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#######################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_$1_node(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_udp_on_$1_node(dollarsone)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_udp_on_$1_node(dollarsone)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_raw_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_raw_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
corenetwork_send_raw_on_$1_node(dollarsone)
|
|
Chris PeBenito |
bd202f |
corenetwork_receive_raw_on_$1_node(dollarsone)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class node udp_send;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class node udp_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_raw_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:node rawip_send;
|
|
Chris PeBenito |
0e730c |
allow dollarsone self:capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_raw_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class node rawip_send;
|
|
Chris PeBenito |
0e730c |
class capability net_raw;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_raw_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_raw_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class node rawip_recv;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_$1_node(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_$1_node',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_node_t:udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_$1_node_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_node_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket node_bind;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
'') dnl end create_node_interfaces
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
# Network port generated macros
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
########################################
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`create_port_interfaces',``
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_tcp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_port_t:tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_tcp_on_$1_port_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket { send_msg recv_msg };
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_network_udp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_network_udp_on_$1_port',`
|
|
Chris PeBenito |
0e730c |
corenetwork_send_udp_on_$1_port(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
corenetwork_receive_udp_on_$1_port(dollarsone,dollarstwo)
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_send_udp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_port_t:udp_socket send_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_send_udp_on_$1_port_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket send_msg;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_receive_udp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_port_t:udp recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_receive_udp_on_$1_port_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket recv_msg;
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_tcp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_$1_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_port_t:tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
$2
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_tcp_on_$1_port_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_port_t;
|
|
Chris PeBenito |
0e730c |
class tcp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
$3
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
#######################################
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
bd202f |
# corenetwork_bind_udp_on_$1_port(domain)
|
|
Chris PeBenito |
0e730c |
#
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_$1_port',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`dollarszero'_depend)
|
|
Chris PeBenito |
0e730c |
allow dollarsone $1_port_t:udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
$2
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`corenetwork_bind_udp_on_$1_port_depend',`
|
|
Chris PeBenito |
0e730c |
type $1_port_t;
|
|
Chris PeBenito |
0e730c |
class udp_socket name_bind;
|
|
Chris PeBenito |
0e730c |
$3
|
|
Chris PeBenito |
0e730c |
')
|
|
Chris PeBenito |
0e730c |
'') dnl end create_port_interfaces
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
# network_interface(linux_interfacename)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`network_interface',`
|
|
Chris PeBenito |
b4cd15 |
ifdef(`interface_pass',`
|
|
Chris PeBenito |
b4cd15 |
create_netif_interfaces($1)
|
|
Chris PeBenito |
b4cd15 |
',`
|
|
Chris PeBenito |
b4cd15 |
type $1_netif_t alias netif_$1_t, netif_type;
|
|
Chris PeBenito |
b4cd15 |
requires_block_template(`type unlabeled_t')
|
|
Chris PeBenito |
b4cd15 |
netifcon $1 system_u:object_r:$1_netif_t system_u:object_r:unlabeled_t
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
# network_node(node_name,address,netmask)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`network_node',`
|
|
Chris PeBenito |
b4cd15 |
ifdef(`interface_pass',`
|
|
Chris PeBenito |
0e730c |
create_node_interfaces($1)
|
|
Chris PeBenito |
b4cd15 |
',`
|
|
Chris PeBenito |
b4cd15 |
type $1_node_t alias node_$1_t, node_type;
|
|
Chris PeBenito |
b4cd15 |
nodecon $2 $3 system_u:object_r:$1_node_t
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
0e730c |
define(`determine_reserved_capability',`dnl
|
|
Chris PeBenito |
0e730c |
ifelse(eval($2 < 1024),1,``allow' dollarsone self:capability net_bind_service;',`dnl
|
|
Chris PeBenito |
0e730c |
ifelse($3,`',`',`determine_reserved_capability(shiftn(2,$*))')dnl end inner ifelse
|
|
Chris PeBenito |
0e730c |
')dnl end outer ifelse
|
|
Chris PeBenito |
0e730c |
') dnl end determine reserved capability
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
0e730c |
define(`determine_reserved_capability_depend',`dnl
|
|
Chris PeBenito |
0e730c |
ifelse(eval($2 < 1024),1,`class capability net_bind_service;',`dnl
|
|
Chris PeBenito |
0e730c |
ifelse($3,`',`',`determine_reserved_capability_depend(shiftn(2,$*))')dnl end inner ifelse
|
|
Chris PeBenito |
0e730c |
')dnl end outer ifelse
|
|
Chris PeBenito |
0e730c |
') dnl end determine reserved capability depend
|
|
Chris PeBenito |
0e730c |
|
|
Chris PeBenito |
b4cd15 |
define(`declare_ports',`dnl
|
|
Chris PeBenito |
b4cd15 |
ifelse(eval($3 < 1024),1,`typeattribute $1 reserved_port_type;',`dnl')
|
|
Chris PeBenito |
b4cd15 |
portcon $2 $3 system_u:object_r:$1
|
|
Chris PeBenito |
b4cd15 |
ifelse(`$4',`',`',`declare_ports($1,shiftn(3,$*))')dnl
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
# network_port(port_name,protocol portnum [,protocol portnum[,...]])
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b4cd15 |
define(`network_port',`
|
|
Chris PeBenito |
b4cd15 |
ifdef(`interface_pass',`
|
|
Chris PeBenito |
0e730c |
create_port_interfaces($1,determine_reserved_capability(shift($*)),determine_reserved_capability_depend(shift($*)))
|
|
Chris PeBenito |
b4cd15 |
',`
|
|
Chris PeBenito |
b4cd15 |
type $1_port_t, port_type;
|
|
Chris PeBenito |
b4cd15 |
declare_ports($1_port_t,shift($*))
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
')
|