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

/external/selinux/libsepol/cil/src/
H A Dcil_reset_ast.c273 static void cil_reset_nodecon(struct cil_nodecon *nodecon) argument
275 if (nodecon->context_str == NULL) {
276 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.c1319 struct cil_nodecon *nodecon = node->data; local
1324 if (nodecon->addr) {
1325 inet_ntop(nodecon->addr->family, &nodecon->addr->ip, buf, 256);
1328 cil_log(CIL_INFO, " %s", nodecon->addr_str);
1331 if (nodecon->mask) {
1332 inet_ntop(nodecon->mask->family, &nodecon->mask->ip, buf, 256);
1335 cil_log(CIL_INFO, " %s", nodecon->mask_str);
1338 if (nodecon
[all...]
H A Dcil_verify.c1061 struct cil_nodecon *nodecon = node->data; local
1062 struct cil_context *ctx = nodecon->context;
1075 cil_log(CIL_ERR, "Invalid nodecon at line %d of %s\n", node->line, node->path);
H A Dcil.c188 CIL_KEY_NODECON = cil_strpool_add("nodecon");
245 cil_sort_init(&(*db)->nodecon);
291 cil_sort_destroy(&(*db)->nodecon);
2165 void cil_nodecon_init(struct cil_nodecon **nodecon) argument
2167 *nodecon = cil_malloc(sizeof(**nodecon));
2169 (*nodecon)->addr_str = NULL;
2170 (*nodecon)->addr = NULL;
2171 (*nodecon)->mask_str = NULL;
2172 (*nodecon)
[all...]
H A Dcil_post.c374 db->nodecon->count++;
492 struct cil_sort *sort = db->nodecon;
1274 struct cil_nodecon *nodecon = node->data; local
1275 rc = __evaluate_levelrange_expression(nodecon->context->range, db);
1619 qsort(db->nodecon->array, db->nodecon->count, sizeof(db->nodecon->array), cil_post_nodecon_compare);
H A Dcil_resolve_ast.c1785 struct cil_nodecon *nodecon = current->data; local
1791 if (nodecon->addr_str != NULL) {
1792 rc = cil_resolve_name(current, nodecon->addr_str, CIL_SYM_IPADDRS, extra_args, &addr_datum);
1796 nodecon->addr = (struct cil_ipaddr*)addr_datum;
1799 if (nodecon->mask_str != NULL) {
1800 rc = cil_resolve_name(current, nodecon->mask_str, CIL_SYM_IPADDRS, extra_args, &mask_datum);
1804 nodecon->mask = (struct cil_ipaddr*)mask_datum;
1807 if (nodecon->context_str != NULL) {
1808 rc = cil_resolve_name(current, nodecon->context_str, CIL_SYM_CONTEXTS, extra_args, &context_datum);
1812 nodecon
[all...]
H A Dcil_build_ast.c4012 struct cil_nodecon *nodecon = NULL; local
4023 cil_nodecon_init(&nodecon);
4026 nodecon->addr_str = parse_current->next->data;
4028 cil_ipaddr_init(&nodecon->addr);
4030 rc = cil_fill_ipaddr(parse_current->next->cl_head, nodecon->addr);
4037 nodecon->mask_str = parse_current->next->next->data;
4039 cil_ipaddr_init(&nodecon->mask);
4041 rc = cil_fill_ipaddr(parse_current->next->next->cl_head, nodecon->mask);
4048 nodecon->context_str = parse_current->next->next->next->data;
4050 cil_context_init(&nodecon
4070 cil_destroy_nodecon(struct cil_nodecon *nodecon) argument
[all...]
H A Dcil_internal.h271 struct cil_sort *nodecon; member in struct:cil_db
939 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 248 milliseconds