| /net/netfilter/ipset/ |
| A D | ip_set_hash_netnet.c | 155 e.ccmp = (HOST_MASK << (sizeof(e.cidr[0]) * 8)) | HOST_MASK; in hash_netnet4_kadt() 159 e.ip[0] &= (ip_set_netmask(e.cidr[0]) & h->bitmask.ip); in hash_netnet4_kadt() 160 e.ip[1] &= (ip_set_netmask(e.cidr[1]) & h->bitmask.ip); in hash_netnet4_kadt() 199 if (!e.cidr[0] || e.cidr[0] > HOST_MASK) in hash_netnet4_uadt() 205 if (!e.cidr[1] || e.cidr[1] > HOST_MASK) in hash_netnet4_uadt() 398 ip6_netmask(&e.ip[0], e.cidr[0]); in hash_netnet6_kadt() 399 ip6_netmask(&e.ip[1], e.cidr[1]); in hash_netnet6_kadt() 443 if (!e.cidr[0] || e.cidr[0] > HOST_MASK) in hash_netnet6_uadt() 449 if (!e.cidr[1] || e.cidr[1] > HOST_MASK) in hash_netnet6_uadt() 453 ip6_netmask(&e.ip[0], e.cidr[0]); in hash_netnet6_uadt() [all …]
|
| A D | ip_set_hash_netportnet.c | 166 &e.port, &e.proto)) in hash_netportnet4_kadt() 171 e.ip[0] &= ip_set_netmask(e.cidr[0]); in hash_netportnet4_kadt() 172 e.ip[1] &= ip_set_netmask(e.cidr[1]); in hash_netportnet4_kadt() 247 e.port = 0; in hash_netportnet4_uadt() 259 e.ip[0] = htonl(ip & ip_set_hostmask(e.cidr[0])); in hash_netportnet4_uadt() 260 e.ip[1] = htonl(ip2_from & ip_set_hostmask(e.cidr[1])); in hash_netportnet4_uadt() 461 &e.port, &e.proto)) in hash_netportnet6_kadt() 466 ip6_netmask(&e.ip[0], e.cidr[0]); in hash_netportnet6_kadt() 467 ip6_netmask(&e.ip[1], e.cidr[1]); in hash_netportnet6_kadt() 520 ip6_netmask(&e.ip[0], e.cidr[0]); in hash_netportnet6_uadt() [all …]
|
| A D | ip_set_list_set.c | 55 struct set_elem *e; in list_set_ktest() local 149 kfree(e); in __list_set_del_rcu() 199 prev = e; in list_set_utest() 251 n = e; in list_set_uadd() 255 next = e; in list_set_uadd() 257 prev = e; in list_set_uadd() 298 if (!e) in list_set_uadd() 300 e->id = d->id; in list_set_uadd() 301 e->set = set; in list_set_uadd() 330 prev = e; in list_set_udel() [all …]
|
| A D | ip_set_hash_ipport.c | 101 &e.port, &e.proto)) in hash_ipport4_kadt() 105 e.ip &= h->bitmask.ip; in hash_ipport4_kadt() 106 if (e.ip == 0) in hash_ipport4_kadt() 140 if (e.ip == 0) in hash_ipport4_uadt() 149 if (e.proto == 0) in hash_ipport4_uadt() 156 e.port = 0; in hash_ipport4_uadt() 193 e.ip = htonl(ip); in hash_ipport4_uadt() 194 e.port = htons(p); in hash_ipport4_uadt() 271 &e.port, &e.proto)) in hash_ipport6_kadt() 328 if (e.proto == 0) in hash_ipport6_uadt() [all …]
|
| A D | ip_set_hash_ipportnet.c | 149 &e.port, &e.proto)) in hash_ipportnet4_kadt() 154 e.ip2 &= ip_set_netmask(e.cidr + 1); in hash_ipportnet4_kadt() 207 if (e.proto == 0) in hash_ipportnet4_uadt() 214 e.port = 0; in hash_ipportnet4_uadt() 227 e.ip = htonl(ip); in hash_ipportnet4_uadt() 228 e.ip2 = htonl(ip2_from & ip_set_hostmask(e.cidr + 1)); in hash_ipportnet4_uadt() 288 &e); in hash_ipportnet4_uadt() 406 &e.port, &e.proto)) in hash_ipportnet6_kadt() 411 ip6_netmask(&e.ip2, e.cidr + 1); in hash_ipportnet6_kadt() 465 ip6_netmask(&e.ip2, e.cidr + 1); in hash_ipportnet6_uadt() [all …]
|
| A D | ip_set_hash_netport.c | 144 &e.port, &e.proto)) in hash_netport4_kadt() 148 e.ip &= ip_set_netmask(e.cidr + 1); in hash_netport4_kadt() 187 e.cidr = cidr - 1; in hash_netport4_uadt() 196 if (e.proto == 0) in hash_netport4_uadt() 203 e.port = 0; in hash_netport4_uadt() 215 e.ip = htonl(ip & ip_set_hostmask(e.cidr + 1)); in hash_netport4_uadt() 246 e.ip = htonl(ip); in hash_netport4_uadt() 364 &e.port, &e.proto)) in hash_netport6_kadt() 368 ip6_netmask(&e.ip, e.cidr + 1); in hash_netport6_kadt() 411 ip6_netmask(&e.ip, e.cidr + 1); in hash_netport6_uadt() [all …]
|
| A D | ip_set_hash_ipportip.c | 99 &e.port, &e.proto)) in hash_ipportip4_kadt() 145 if (e.proto == 0) in hash_ipportip4_uadt() 152 e.port = 0; in hash_ipportip4_uadt() 161 ip_to = ip = ntohl(e.ip); in hash_ipportip4_uadt() 189 e.ip = htonl(ip); in hash_ipportip4_uadt() 190 e.port = htons(p); in hash_ipportip4_uadt() 269 &e.port, &e.proto)) in hash_ipportip6_kadt() 323 if (e.proto == 0) in hash_ipportip6_uadt() 330 e.port = 0; in hash_ipportip6_uadt() 337 port = ntohs(e.port); in hash_ipportip6_uadt() [all …]
|
| A D | ip_set_hash_ipmac.c | 72 const struct hash_ipmac4_elem *e) in hash_ipmac4_data_next() argument 74 next->ip = e->ip; in hash_ipmac4_data_next() 101 if (is_zero_ether_addr(e.ether)) in hash_ipmac4_kadt() 137 if (is_zero_ether_addr(e.ether)) in hash_ipmac4_uadt() 140 return adtfn(set, &e, &ext, &ext, flags); in hash_ipmac4_uadt() 180 const struct hash_ipmac6_elem *e) in hash_ipmac6_data_next() argument 202 struct hash_ipmac6_elem e = { in hash_ipmac6_kadt() local 217 if (is_zero_ether_addr(e.ether)) in hash_ipmac6_kadt() 230 struct hash_ipmac6_elem e = { in hash_ipmac6_uadt() local 257 if (is_zero_ether_addr(e.ether)) in hash_ipmac6_uadt() [all …]
|
| A D | ip_set_hash_netiface.c | 173 e.ip &= ip_set_netmask(e.cidr); in hash_netiface4_kadt() 186 e.physdev = 1; in hash_netiface4_kadt() 235 e.physdev = 1; in hash_netiface4_uadt() 239 e.wildcard = 1; in hash_netiface4_uadt() 242 e.ip = htonl(ip & ip_set_hostmask(e.cidr)); in hash_netiface4_uadt() 264 e.ip = htonl(ip); in hash_netiface4_uadt() 394 ip6_netmask(&e.ip, e.cidr); in hash_netiface6_kadt() 404 e.physdev = 1; in hash_netiface6_kadt() 449 ip6_netmask(&e.ip, e.cidr); in hash_netiface6_uadt() 457 e.physdev = 1; in hash_netiface6_uadt() [all …]
|
| A D | ip_set_hash_net.c | 124 if (e.cidr == 0) in hash_net4_kadt() 127 e.cidr = HOST_MASK; in hash_net4_kadt() 130 e.ip &= ip_set_netmask(e.cidr); in hash_net4_kadt() 163 if (!e.cidr || e.cidr > HOST_MASK) in hash_net4_uadt() 175 e.ip = htonl(ip & ip_set_hostmask(e.cidr)); in hash_net4_uadt() 196 e.ip = htonl(ip); in hash_net4_uadt() 298 if (e.cidr == 0) in hash_net6_kadt() 301 e.cidr = HOST_MASK; in hash_net6_kadt() 304 ip6_netmask(&e.ip, e.cidr); in hash_net6_kadt() 337 if (!e.cidr || e.cidr > HOST_MASK) in hash_net6_uadt() [all …]
|
| A D | ip_set_hash_ipmark.c | 86 struct hash_ipmark4_elem e = { }; in hash_ipmark4_kadt() local 89 e.mark = skb->mark; in hash_ipmark4_kadt() 90 e.mark &= h->markmask; in hash_ipmark4_kadt() 123 e.mark &= h->markmask; in hash_ipmark4_uadt() 124 if (e.mark == 0 && e.ip == 0) in hash_ipmark4_uadt() 133 ip_to = ip = ntohl(e.ip); in hash_ipmark4_uadt() 139 if (e.mark == 0 && ip_to == 0) in hash_ipmark4_uadt() 154 e.ip = htonl(ip); in hash_ipmark4_uadt() 224 e.mark = skb->mark; in hash_ipmark6_kadt() 225 e.mark &= h->markmask; in hash_ipmark6_kadt() [all …]
|
| A D | ip_set_hash_ip.c | 72 next->ip = e->ip; in hash_ip4_data_next() 86 struct hash_ip4_elem e = { 0 }; in hash_ip4_kadt() local 95 e.ip = ip; in hash_ip4_kadt() 105 struct hash_ip4_elem e = { 0 }; in hash_ip4_uadt() local 125 e.ip = htonl(ip); in hash_ip4_uadt() 126 if (e.ip == 0) in hash_ip4_uadt() 155 e.ip = htonl(ip); in hash_ip4_uadt() 157 hash_ip4_data_next(&h->next, &e); in hash_ip4_uadt() 160 ret = adtfn(set, &e, &ext, &ext, flags); in hash_ip4_uadt() 227 if (ipv6_addr_any(&e.ip.in6)) in hash_ip6_kadt() [all …]
|
| A D | ip_set_bitmap_ipmac.c | 88 if (!test_bit(e->id, map->members)) in bitmap_ipmac_do_test() 134 if (e->add_mac) in bitmap_ipmac_add_timeout() 151 if (e->add_mac && in bitmap_ipmac_do_add() 155 clear_bit(e->id, map->members); in bitmap_ipmac_do_add() 160 } else if (!e->add_mac) in bitmap_ipmac_do_add() 164 clear_bit(e->id, map->members); in bitmap_ipmac_do_add() 169 } else if (e->add_mac) { in bitmap_ipmac_do_add() 227 e.id = ip_to_id(map, ip); in bitmap_ipmac_kadt() 234 if (is_zero_ether_addr(e.ether)) in bitmap_ipmac_kadt() 268 e.id = ip_to_id(map, ip); in bitmap_ipmac_uadt() [all …]
|
| A D | ip_set_hash_mac.c | 51 if (nla_put(skb, IPSET_ATTR_ETHER, ETH_ALEN, e->ether)) in hash_mac4_data_list() 61 const struct hash_mac4_elem *e) in hash_mac4_data_next() argument 77 struct hash_mac4_elem e = { { .foo[0] = 0, .foo[1] = 0 } }; in hash_mac4_kadt() local 85 ether_addr_copy(e.ether, eth_hdr(skb)->h_source); in hash_mac4_kadt() 87 ether_addr_copy(e.ether, eth_hdr(skb)->h_dest); in hash_mac4_kadt() 89 if (is_zero_ether_addr(e.ether)) in hash_mac4_kadt() 91 return adtfn(set, &e, &ext, &opt->ext, opt->cmdflags); in hash_mac4_kadt() 99 struct hash_mac4_elem e = { { .foo[0] = 0, .foo[1] = 0 } }; in hash_mac4_uadt() local 113 ether_addr_copy(e.ether, nla_data(tb[IPSET_ATTR_ETHER])); in hash_mac4_uadt() 114 if (is_zero_ether_addr(e.ether)) in hash_mac4_uadt() [all …]
|
| /net/netfilter/ |
| A D | xt_recent.c | 138 memcmp(&e->addr, addrp, sizeof(e->addr)) == 0 && in recent_entry_lookup() 139 (ttl == e->ttl || ttl == 0 || e->ttl == 0)) in recent_entry_lookup() 148 kfree(e); in recent_entry_remove() 174 if (time_after(time, e->stamps[e->index-1])) in recent_entry_reap() 194 memcpy(&e->addr, addr, sizeof(e->addr)); in recent_entry_init() 206 return e; in recent_entry_init() 212 e->stamps[e->index++] = jiffies; in recent_entry_update() 213 if (e->index > e->nstamps) in recent_entry_update() 214 e->nstamps = e->index; in recent_entry_update() 529 &e->addr.ip, e->ttl, e->stamps[i], e->index); in recent_seq_show() [all …]
|
| A D | nf_conntrack_ecache.c | 185 if (!e) in nf_conntrack_eventmask_report() 191 item.portid = e->portid ? e->portid : portid; in nf_conntrack_eventmask_report() 195 missed = e->portid ? 0 : e->missed; in nf_conntrack_eventmask_report() 205 e->portid = portid; in nf_conntrack_eventmask_report() 224 if (e == NULL) in nf_ct_deliver_cached_events() 237 __nf_conntrack_eventmask_report(e, events, e->missed, &item); in nf_ct_deliver_cached_events() 256 if (!e) in nf_ct_expect_event_report() 350 if (e) { in nf_ct_ecache_ext_add() 352 e->ctmask = ctmask; in nf_ct_ecache_ext_add() 353 e->expmask = expmask; in nf_ct_ecache_ext_add() [all …]
|
| A D | nft_set_pipapo.c | 475 e = f->mt[b].e; in pipapo_get() 528 return e ? &e->ext : NULL; in nft_pipapo_lookup() 553 if (!e) in nft_pipapo_get() 1135 f->mt[map[i].to + j].e = e; 1504 if (r != first && e != f->mt[r].e) 1507 e = f->mt[r].e; 1692 e = f->mt[rulemap[i].to].e; 1844 if (!e) 2049 if (last && f->mt[rulemap[i].to].e == e) { 2091 e = f->mt[r].e; [all …]
|
| A D | xt_policy.c | 35 match_xfrm_state(const struct xfrm_state *x, const struct xt_policy_elem *e, in match_xfrm_state() argument 38 #define MATCH_ADDR(x,y,z) (!e->match.x || \ in match_xfrm_state() 39 (xt_addr_cmp(&e->x, &e->y, (const union nf_inet_addr *)(z), family) \ in match_xfrm_state() 40 ^ e->invert.x)) in match_xfrm_state() 41 #define MATCH(x,y) (!e->match.x || ((e->x == (y)) ^ e->invert.x)) in match_xfrm_state() 55 const struct xt_policy_elem *e; in match_policy_in() local 69 e = &info->pol[pos]; in match_policy_in() 71 if (match_xfrm_state(sp->xvec[i], e, family)) { in match_policy_in() 85 const struct xt_policy_elem *e; in match_policy_out() local 98 e = &info->pol[pos]; in match_policy_out() [all …]
|
| /net/ipv4/netfilter/ |
| A D | ip_tables.c | 282 WARN_ON(!e); in ipt_do_table() 286 e = ipt_next_entry(e); in ipt_do_table() 325 e = ipt_next_entry(e); in ipt_do_table() 349 e = ipt_next_entry(e); in ipt_do_table() 511 e->ip.proto, e->ip.invflags & IPT_INV_PROTO); in check_target() 600 (unsigned char *)e + e->next_offset > limit) in check_entry_size_and_hooks() 610 err = xt_check_entry_offsets(e, e->elems, e->target_offset, in check_entry_size_and_hooks() 835 if (copy_to_user(userptr + off, e, sizeof(*e))) { in copy_entries_to_user() 1301 (unsigned char *)e + e->next_offset > limit) in check_compat_entry_size_and_hooks() 1311 ret = xt_compat_check_entry_offsets(e, e->elems, in check_compat_entry_size_and_hooks() [all …]
|
| A D | arp_tables.c | 226 e = arpt_next_entry(e); in arpt_do_table() 251 e = arpt_next_entry(e); in arpt_do_table() 275 e = arpt_next_entry(e); in arpt_do_table() 329 e->comefrom in mark_source_chains() 394 .entryinfo = e, in check_target() 465 (unsigned char *)e + e->next_offset > limit) in check_entry_size_and_hooks() 475 err = xt_check_entry_offsets(e, e->elems, e->target_offset, in check_entry_size_and_hooks() 693 if (copy_to_user(userptr + off, e, sizeof(*e))) { in copy_entries_to_user() 1087 (unsigned char *)e + e->next_offset > limit) in check_compat_entry_size_and_hooks() 1097 ret = xt_compat_check_entry_offsets(e, e->elems, e->target_offset, in check_compat_entry_size_and_hooks() [all …]
|
| /net/ipv6/netfilter/ |
| A D | ip6_tables.c | 304 WARN_ON(!e); in ip6t_do_table() 309 e = ip6t_next_entry(e); in ip6t_do_table() 368 e = ip6t_next_entry(e); in ip6t_do_table() 521 .entryinfo = e, in check_target() 618 (unsigned char *)e + e->next_offset > limit) in check_entry_size_and_hooks() 628 err = xt_check_entry_offsets(e, e->elems, e->target_offset, in check_entry_size_and_hooks() 851 if (copy_to_user(userptr + off, e, sizeof(*e))) { in copy_entries_to_user() 1317 (unsigned char *)e + e->next_offset > limit) in check_compat_entry_size_and_hooks() 1327 ret = xt_compat_check_entry_offsets(e, e->elems, in check_compat_entry_size_and_hooks() 1328 e->target_offset, e->next_offset); in check_compat_entry_size_and_hooks() [all …]
|
| /net/bridge/netfilter/ |
| A D | ebtables.c | 147 NF_INVF(e, EBT_IPROTO, e->ethproto != ethproto)) in ebt_basic_match() 150 if (NF_INVF(e, EBT_IIN, ebt_dev_check(e->in, in))) in ebt_basic_match() 152 if (NF_INVF(e, EBT_IOUT, ebt_dev_check(e->out, out))) in ebt_basic_match() 571 e->watchers_offset > e->target_offset || in ebt_check_entry_size_and_hooks() 572 e->target_offset >= e->next_offset) in ebt_check_entry_size_and_hooks() 747 gap = e->next_offset - e->target_offset; in ebt_check_entry() 811 e = cl_s[chain_nr].cs.e; in check_chainloops() 850 cl_s[i].cs.e = ebt_next_entry(e); in check_chainloops() 860 e = ebt_next_entry(e); in check_chainloops() 1487 if (copy_to_user(ubase + ((char *)e - base), e, in ebt_entry_to_user() [all …]
|
| /net/ipv4/ |
| A D | ipconfig.c | 690 e += 4; in ic_dhcp_init_options() 693 *e++ = 1; in ic_dhcp_init_options() 700 e += 4; in ic_dhcp_init_options() 705 e += 4; in ic_dhcp_init_options() 763 e += 4; in ic_bootp_init_ext() 765 *e++ = 4; in ic_bootp_init_ext() 766 e += 4; in ic_bootp_init_ext() 769 e += 4; in ic_bootp_init_ext() 777 e += 32; in ic_bootp_init_ext() 780 e += 32; in ic_bootp_init_ext() [all …]
|
| /net/netfilter/ipvs/ |
| A D | ip_vs_lblcr.c | 106 if (e->dest == dest) in ip_vs_dest_set_insert() 111 e = kmalloc(sizeof(*e), GFP_ATOMIC); in ip_vs_dest_set_insert() 112 if (e == NULL) in ip_vs_dest_set_insert() 116 e->dest = dest; in ip_vs_dest_set_insert() 130 kfree(e); in ip_vs_lblcr_elem_rcu_free() 139 if (e->dest == dest) { in ip_vs_dest_set_erase() 155 list_del_rcu(&e->list); in ip_vs_dest_set_eraseall() 169 least = e->dest; in ip_vs_dest_set_min() 184 dest = e->dest; in ip_vs_dest_set_min() 221 most = e->dest; in ip_vs_dest_set_max() [all …]
|
| /net/mptcp/ |
| A D | syncookies.c | 98 struct join_entry *e; in mptcp_token_join_cookie_init_state() local 100 e = &join_entries[i]; in mptcp_token_join_cookie_init_state() 104 if (e->valid == 0) { in mptcp_token_join_cookie_init_state() 109 e->valid = 0; in mptcp_token_join_cookie_init_state() 111 msk = mptcp_token_get_sock(net, e->token); in mptcp_token_join_cookie_init_state() 117 subflow_req->remote_nonce = e->remote_nonce; in mptcp_token_join_cookie_init_state() 118 subflow_req->local_nonce = e->local_nonce; in mptcp_token_join_cookie_init_state() 119 subflow_req->backup = e->backup; in mptcp_token_join_cookie_init_state() 120 subflow_req->remote_id = e->join_id; in mptcp_token_join_cookie_init_state() 121 subflow_req->token = e->token; in mptcp_token_join_cookie_init_state()
|