Lines Matching refs:port
43 ocontext_t ** port, const sepol_port_t * data) in port_from_record() argument
62 tmp_port->u.port.protocol = tmp_proto; in port_from_record()
65 tmp_port->u.port.low_port = low; in port_from_record()
66 tmp_port->u.port.high_port = high; in port_from_record()
67 if (tmp_port->u.port.low_port > tmp_port->u.port.high_port) { in port_from_record()
69 tmp_port->u.port.low_port, tmp_port->u.port.high_port); in port_from_record()
82 *port = tmp_port; in port_from_record()
102 ocontext_t * port, sepol_port_t ** record) in port_to_record() argument
105 int proto = port->u.port.protocol; in port_to_record()
106 int low = port->u.port.low_port; in port_to_record()
107 int high = port->u.port.high_port; in port_to_record()
108 context_struct_t *con = &port->context[0]; in port_to_record()
180 int proto2 = c->u.port.protocol; in sepol_port_exists()
181 int low2 = c->u.port.low_port; in sepol_port_exists()
182 int high2 = c->u.port.high_port; in sepol_port_exists()
218 int proto2 = c->u.port.protocol; in sepol_port_query()
219 int low2 = c->u.port.low_port; in sepol_port_query()
220 int high2 = c->u.port.high_port; in sepol_port_query()
246 ocontext_t *port = NULL; in sepol_port_modify() local
257 if (port_from_record(handle, policydb, &port, data) < 0) in sepol_port_modify()
261 port->next = policydb->ocontexts[OCON_PORT]; in sepol_port_modify()
262 policydb->ocontexts[OCON_PORT] = port; in sepol_port_modify()
269 if (port != NULL) { in sepol_port_modify()
270 context_destroy(&port->context[0]); in sepol_port_modify()
271 free(port); in sepol_port_modify()
278 int (*fn) (const sepol_port_t * port, in sepol_port_iterate()
284 sepol_port_t *port = NULL; in sepol_port_iterate() local
290 if (port_to_record(handle, policydb, c, &port) < 0) in sepol_port_iterate()
294 status = fn(port, arg); in sepol_port_iterate()
298 sepol_port_free(port); in sepol_port_iterate()
299 port = NULL; in sepol_port_iterate()
310 sepol_port_free(port); in sepol_port_iterate()