Searched defs:nodecon (Results 1 - 10 of 10) sorted by relevance

/external/selinux/libsepol/cil/src/
H A Dcil_reset_ast.c298 static void cil_reset_nodecon(struct cil_nodecon *nodecon) argument
300 if (nodecon->context_str == NULL) {
301 cil_reset_context(nodecon->context);
H A Dcil_policy.c173 struct cil_nodecon *nodecon = (struct cil_nodecon*)sort->array[i]; local
176 if (nodecon->addr->family == AF_INET) {
178 inet_ntop(nodecon->addr->family, &nodecon->addr->ip.v4, buf, INET_ADDRSTRLEN);
179 } else if (nodecon->addr->family == AF_INET6) {
181 inet_ntop(nodecon->addr->family, &nodecon->addr->ip.v6, buf, INET6_ADDRSTRLEN);
190 fprintf(file_arr[NETIFCONS], "nodecon %s ", buf);
193 if (nodecon->mask->family == AF_INET) {
195 inet_ntop(nodecon
[all...]
H A Dcil_tree.c1335 struct cil_nodecon *nodecon = node->data; local
1340 if (nodecon->addr) {
1341 inet_ntop(nodecon->addr->family, &nodecon->addr->ip, buf, 256);
1344 cil_log(CIL_INFO, " %s", nodecon->addr_str);
1347 if (nodecon->mask) {
1348 inet_ntop(nodecon->mask->family, &nodecon->mask->ip, buf, 256);
1351 cil_log(CIL_INFO, " %s", nodecon->mask_str);
1354 if (nodecon
[all...]
H A Dcil_verify.c1065 struct cil_nodecon *nodecon = node->data; local
1066 struct cil_context *ctx = nodecon->context;
1079 cil_log(CIL_ERR, "Invalid nodecon at line %d of %s\n", node->line, node->path);
H A Dcil.c190 CIL_KEY_NODECON = cil_strpool_add("nodecon");
254 cil_sort_init(&(*db)->nodecon);
303 cil_sort_destroy(&(*db)->nodecon);
2225 void cil_nodecon_init(struct cil_nodecon **nodecon) argument
2227 *nodecon = cil_malloc(sizeof(**nodecon));
2229 (*nodecon)->addr_str = NULL;
2230 (*nodecon)->addr = NULL;
2231 (*nodecon)->mask_str = NULL;
2232 (*nodecon)
[all...]
H A Dcil_post.c399 db->nodecon->count++;
525 struct cil_sort *sort = db->nodecon;
1588 struct cil_nodecon *nodecon = node->data; local
1589 rc = __evaluate_levelrange_expression(nodecon->context->range, db);
1939 qsort(db->nodecon->array, db->nodecon->count, sizeof(db->nodecon->array), cil_post_nodecon_compare);
H A Dcil_resolve_ast.c1921 struct cil_nodecon *nodecon = current->data; local
1927 if (nodecon->addr_str != NULL) {
1928 rc = cil_resolve_name(current, nodecon->addr_str, CIL_SYM_IPADDRS, extra_args, &addr_datum);
1932 nodecon->addr = (struct cil_ipaddr*)addr_datum;
1935 if (nodecon->mask_str != NULL) {
1936 rc = cil_resolve_name(current, nodecon->mask_str, CIL_SYM_IPADDRS, extra_args, &mask_datum);
1940 nodecon->mask = (struct cil_ipaddr*)mask_datum;
1943 if (nodecon->context_str != NULL) {
1944 rc = cil_resolve_name(current, nodecon->context_str, CIL_SYM_CONTEXTS, extra_args, &context_datum);
1948 nodecon
[all...]
H A Dcil_build_ast.c4344 struct cil_nodecon *nodecon = NULL; local
4355 cil_nodecon_init(&nodecon);
4358 nodecon->addr_str = parse_current->next->data;
4360 cil_ipaddr_init(&nodecon->addr);
4362 rc = cil_fill_ipaddr(parse_current->next->cl_head, nodecon->addr);
4369 nodecon->mask_str = parse_current->next->next->data;
4371 cil_ipaddr_init(&nodecon->mask);
4373 rc = cil_fill_ipaddr(parse_current->next->next->cl_head, nodecon->mask);
4380 nodecon->context_str = parse_current->next->next->next->data;
4382 cil_context_init(&nodecon
4402 cil_destroy_nodecon(struct cil_nodecon *nodecon) argument
[all...]
H A Dcil_internal.h281 struct cil_sort *nodecon; member in struct:cil_db
984 void cil_nodecon_init(struct cil_nodecon **nodecon);
/external/selinux/libsepol/cil/test/unit/
H A Dtest_cil_build_ast.c13157 char *line[] = {"(", "nodecon", "(", "192.168.1.1", ")", "ipaddr", "con", ")", NULL};
13171 struct cil_nodecon *nodecon; local
13172 cil_nodecon_init(&nodecon);
13173 cil_ipaddr_init(&nodecon->addr);
13175 int rc = cil_fill_ipaddr(test_tree->root->cl_head->cl_head->next->cl_head, nodecon->addr);
13180 char *line[] = {"(", "nodecon", "(", "192.168.1.1", ")", "ipaddr", "con", ")", NULL};
13194 struct cil_nodecon *nodecon; local
13195 cil_nodecon_init(&nodecon);
13196 cil_ipaddr_init(&nodecon->addr);
13198 int rc = cil_fill_ipaddr(NULL, nodecon
13217 struct cil_nodecon *nodecon; local
13240 struct cil_nodecon *nodecon; local
13263 struct cil_nodecon *nodecon; local
[all...]

Completed in 326 milliseconds