/net/ipv4/netfilter/ |
D | nf_nat_sip.c | 63 if (ct->tuplehash[dir].tuple.src.u3.ip == addr->ip && in map_addr() 65 newaddr = ct->tuplehash[!dir].tuple.dst.u3.ip; in map_addr() 67 } else if (ct->tuplehash[dir].tuple.dst.u3.ip == addr->ip && in map_addr() 69 newaddr = ct->tuplehash[!dir].tuple.src.u3.ip; in map_addr() 74 if (newaddr == addr->ip && newport == port) in map_addr() 132 if (addr.ip != ct->tuplehash[dir].tuple.src.u3.ip || in ip_nat_sip() 136 if (addr.ip != ct->tuplehash[dir].tuple.dst.u3.ip || in ip_nat_sip() 152 addr.ip == ct->tuplehash[dir].tuple.src.u3.ip && in ip_nat_sip() 153 addr.ip != ct->tuplehash[!dir].tuple.dst.u3.ip) { in ip_nat_sip() 155 &ct->tuplehash[!dir].tuple.dst.u3.ip); in ip_nat_sip() [all …]
|
D | nf_nat_h323.c | 27 unsigned int addroff, __be32 ip, __be16 port) in set_addr() argument 32 __be32 ip; in set_addr() member 38 buf.ip = ip; in set_addr() 82 return set_addr(skb, data, dataoff, taddr->ipAddress.ip, in set_h225_addr() 83 addr->ip, port); in set_h225_addr() 94 addr->ip, port); in set_h245_addr() 111 if (addr.ip == ct->tuplehash[dir].tuple.src.u3.ip && in set_sig_addr() 119 (ntohl(addr.ip) & 0xff000000) == 0x7f000000) in set_sig_addr() 123 &addr.ip, port, in set_sig_addr() 124 &ct->tuplehash[!dir].tuple.dst.u3.ip, in set_sig_addr() [all …]
|
D | nf_conntrack_l3proto_ipv4.c | 45 tuple->src.u3.ip = ap[0]; in ipv4_pkt_to_tuple() 46 tuple->dst.u3.ip = ap[1]; in ipv4_pkt_to_tuple() 54 tuple->src.u3.ip = orig->dst.u3.ip; in ipv4_invert_tuple() 55 tuple->dst.u3.ip = orig->src.u3.ip; in ipv4_invert_tuple() 64 &tuple->src.u3.ip, &tuple->dst.u3.ip); in ipv4_print_tuple() 252 tuple.src.u3.ip = inet->rcv_saddr; in getorigdst() 254 tuple.dst.u3.ip = inet->daddr; in getorigdst() 280 .tuple.dst.u3.ip; in getorigdst() 292 &tuple.src.u3.ip, ntohs(tuple.src.u.tcp.port), in getorigdst() 293 &tuple.dst.u3.ip, ntohs(tuple.dst.u.tcp.port)); in getorigdst() [all …]
|
D | nf_nat_core.c | 80 hash = jhash_3words((__force u32)tuple->src.u3.ip, in hash_by_src() 115 if (ntohl(tuple->src.u3.ip) < ntohl(range->min_ip) || in in_range() 116 ntohl(tuple->src.u3.ip) > ntohl(range->max_ip)) in in_range() 139 t->src.u3.ip == tuple->src.u3.ip && in same_src() 195 var_ipp = &tuple->src.u3.ip; in find_best_ips_proto() 197 var_ipp = &tuple->dst.u3.ip; in find_best_ips_proto() 213 j = jhash_2words((__force u32)tuple->src.u3.ip, in find_best_ips_proto() 214 (__force u32)tuple->dst.u3.ip, 0); in find_best_ips_proto() 378 csum_replace4(&iph->check, iph->saddr, target->src.u3.ip); in manip_pkt() 379 iph->saddr = target->src.u3.ip; in manip_pkt() [all …]
|
D | nf_nat_irc.c | 37 u_int32_t ip; in help() local 56 ip = ntohl(exp->master->tuplehash[IP_CT_DIR_REPLY].tuple.dst.u3.ip); in help() 57 sprintf(buffer, "%u %u", ip, port); in help() 59 buffer, &ip, port); in help()
|
D | nf_nat_pptp.c | 59 t.src.u3.ip = master->tuplehash[!exp->dir].tuple.src.u3.ip; in pptp_nat_expected() 61 t.dst.u3.ip = master->tuplehash[!exp->dir].tuple.dst.u3.ip; in pptp_nat_expected() 68 t.src.u3.ip = master->tuplehash[!exp->dir].tuple.src.u3.ip; in pptp_nat_expected() 70 t.dst.u3.ip = master->tuplehash[!exp->dir].tuple.dst.u3.ip; in pptp_nat_expected() 92 = ct->master->tuplehash[!exp->dir].tuple.dst.u3.ip; in pptp_nat_expected() 102 = ct->master->tuplehash[!exp->dir].tuple.src.u3.ip; in pptp_nat_expected()
|
D | nf_nat_rule.c | 138 __be32 ip in alloc_null_binding() local 140 ? ct->tuplehash[IP_CT_DIR_REPLY].tuple.dst.u3.ip in alloc_null_binding() 141 : ct->tuplehash[IP_CT_DIR_REPLY].tuple.src.u3.ip); in alloc_null_binding() 143 = { IP_NAT_RANGE_MAP_IPS, ip, ip, { 0 }, { 0 } }; in alloc_null_binding() 145 pr_debug("Allocating NULL binding for %p (%pI4)\n", ct, &ip); in alloc_null_binding()
|
D | ip_tables.c | 80 ip_packet_match(const struct iphdr *ip, in ip_packet_match() argument 91 if (FWINV((ip->saddr&ipinfo->smsk.s_addr) != ipinfo->src.s_addr, in ip_packet_match() 93 || FWINV((ip->daddr&ipinfo->dmsk.s_addr) != ipinfo->dst.s_addr, in ip_packet_match() 98 &ip->saddr, &ipinfo->smsk.s_addr, &ipinfo->src.s_addr, in ip_packet_match() 101 &ip->daddr, &ipinfo->dmsk.s_addr, &ipinfo->dst.s_addr, in ip_packet_match() 135 && FWINV(ip->protocol != ipinfo->proto, IPT_INV_PROTO)) { in ip_packet_match() 137 ip->protocol, ipinfo->proto, in ip_packet_match() 154 ip_checkentry(const struct ipt_ip *ip) in ip_checkentry() argument 156 if (ip->flags & ~IPT_F_MASK) { in ip_checkentry() 158 ip->flags & ~IPT_F_MASK); in ip_checkentry() [all …]
|
D | ipt_CLUSTERIP.c | 147 clusterip_config_init(const struct ipt_clusterip_tgt_info *i, __be32 ip, in clusterip_config_init() argument 157 c->clusterip = ip; in clusterip_config_init() 171 sprintf(buffer, "%pI4", &ip); in clusterip_config_init() 365 if (e->ip.dmsk.s_addr != htonl(0xffffffff) in clusterip_tg_check() 366 || e->ip.dst.s_addr == 0) { in clusterip_tg_check() 373 config = clusterip_config_find_get(e->ip.dst.s_addr, 1); in clusterip_tg_check() 376 printk(KERN_WARNING "CLUSTERIP: no config found for %pI4, need 'new'\n", &e->ip.dst.s_addr); in clusterip_tg_check() 381 if (e->ip.iniface[0] == '\0') { in clusterip_tg_check() 386 dev = dev_get_by_name(&init_net, e->ip.iniface); in clusterip_tg_check() 388 printk(KERN_WARNING "CLUSTERIP: no such interface %s\n", e->ip.iniface); in clusterip_tg_check() [all …]
|
D | nf_nat_standalone.c | 51 fl->fl4_dst = t->dst.u3.ip; in nat_decode_session() 63 fl->fl4_src = t->src.u3.ip; in nat_decode_session() 201 if (ct->tuplehash[dir].tuple.src.u3.ip != in nf_nat_out() 202 ct->tuplehash[!dir].tuple.dst.u3.ip in nf_nat_out() 233 if (ct->tuplehash[dir].tuple.dst.u3.ip != in nf_nat_local_fn() 234 ct->tuplehash[!dir].tuple.src.u3.ip) { in nf_nat_local_fn()
|
/net/atm/ |
D | mpoa_proc.c | 232 unsigned char ip[4]; in parse_qos() local 240 ip, ip+1, ip+2, ip+3) == 4) { in parse_qos() 241 ipaddr = *(__be32 *)ip; in parse_qos() 246 ip, ip+1, ip+2, ip+3, &tx_pcr, &tx_sdu) == 6) { in parse_qos() 250 ip, ip+1, ip+2, ip+3, &tx_pcr, &tx_sdu, &rx_pcr, &rx_sdu) != 8) in parse_qos() 253 ipaddr = *(__be32 *)ip; in parse_qos()
|
D | clip.c | 48 static int to_atmarpd(enum atmarp_ctrl_type type, int itf, __be32 ip) in to_atmarpd() argument 63 ctrl->ip = ip; in to_atmarpd() 259 to_atmarpd(act_need, PRIV(neigh->dev)->number, NEIGH2ENTRY(neigh)->ip); in clip_neigh_solicit() 288 neigh->type = inet_addr_type(&init_net, entry->ip); in clip_constructor() 397 to_atmarpd(act_need, PRIV(dev)->number, entry->ip); in clip_start_xmit() 514 static int clip_setentry(struct atm_vcc *vcc, __be32 ip) in clip_setentry() argument 520 struct flowi fl = { .nl_u = { .ip4_u = { .daddr = ip, .tos = 1}} }; in clip_setentry() 528 if (!ip) { in clip_setentry() 540 neigh = __neigh_lookup(&clip_tbl, &ip, rt->u.dst.dev, 1); in clip_setentry() 826 &entry->ip); in atmarp_info()
|
/net/netfilter/ |
D | xt_multiport.c | 163 const struct ipt_ip *ip = par->entryinfo; in multiport_mt_check_v0() local 166 return check(ip->proto, ip->invflags, multiinfo->flags, in multiport_mt_check_v0() 172 const struct ipt_ip *ip = par->entryinfo; in multiport_mt_check() local 175 return check(ip->proto, ip->invflags, multiinfo->flags, in multiport_mt_check() 181 const struct ip6t_ip6 *ip = par->entryinfo; in multiport_mt6_check_v0() local 184 return check(ip->proto, ip->invflags, multiinfo->flags, in multiport_mt6_check_v0() 190 const struct ip6t_ip6 *ip = par->entryinfo; in multiport_mt6_check() local 193 return check(ip->proto, ip->invflags, multiinfo->flags, in multiport_mt6_check()
|
D | xt_iprange.c | 60 m = ntohl(iph->saddr) < ntohl(info->src_min.ip); in iprange_mt4() 61 m |= ntohl(iph->saddr) > ntohl(info->src_max.ip); in iprange_mt4() 67 &info->src_max.ip, in iprange_mt4() 68 &info->src_max.ip); in iprange_mt4() 73 m = ntohl(iph->daddr) < ntohl(info->dst_min.ip); in iprange_mt4() 74 m |= ntohl(iph->daddr) > ntohl(info->dst_max.ip); in iprange_mt4() 80 &info->dst_min.ip, in iprange_mt4() 81 &info->dst_max.ip); in iprange_mt4()
|
D | xt_conntrack.c | 71 FWINV((ct->tuplehash[IP_CT_DIR_ORIGINAL].tuple.src.u3.ip & in conntrack_mt_v0() 73 sinfo->tuple[IP_CT_DIR_ORIGINAL].src.ip, in conntrack_mt_v0() 78 FWINV((ct->tuplehash[IP_CT_DIR_ORIGINAL].tuple.dst.u3.ip & in conntrack_mt_v0() 80 sinfo->tuple[IP_CT_DIR_ORIGINAL].dst.ip, in conntrack_mt_v0() 85 FWINV((ct->tuplehash[IP_CT_DIR_REPLY].tuple.src.u3.ip & in conntrack_mt_v0() 87 sinfo->tuple[IP_CT_DIR_REPLY].src.ip, in conntrack_mt_v0() 92 FWINV((ct->tuplehash[IP_CT_DIR_REPLY].tuple.dst.u3.ip & in conntrack_mt_v0() 94 sinfo->tuple[IP_CT_DIR_REPLY].dst.ip, in conntrack_mt_v0() 122 return ((kaddr->ip ^ uaddr->ip) & umask->ip) == 0; in conntrack_addrcmp()
|
D | xt_connlimit.c | 88 return (addr->ip & mask->ip) == (u3->ip & mask->ip); in same_source_net() 120 hash = &data->iphash[connlimit_iphash(addr->ip & mask->ip)]; in count_them() 203 addr.ip = iph->saddr; in connlimit_mt()
|
D | nf_conntrack_irc.c | 69 static int parse_dcc(char *data, const char *data_end, u_int32_t *ip, in parse_dcc() argument 88 *ip = simple_strtoul(data, &data, 10); in parse_dcc() 185 if (tuple->src.u3.ip != htonl(dcc_ip) && in help() 186 tuple->dst.u3.ip != htonl(dcc_ip)) { in help() 190 &tuple->src.u3.ip, in help()
|
D | xt_policy.c | 30 return ((a1->ip ^ a2->ip) & m->ip) == 0; in xt_addr_cmp()
|
/net/netfilter/ipvs/ |
D | ip_vs_ftp.c | 177 &from.ip, &port, in ip_vs_ftp_out() 182 &from.ip, ntohs(port), &cp->caddr.ip, 0); in ip_vs_ftp_out() 206 from.ip = n_cp->vaddr.ip; in ip_vs_ftp_out() 208 sprintf(buf, "%d,%d,%d,%d,%d,%d", NIPQUAD(from.ip), in ip_vs_ftp_out() 309 '\r', &to.ip, &port, in ip_vs_ftp_in() 313 IP_VS_DBG(7, "PORT %pI4:%d detected\n", &to.ip, ntohs(port)); in ip_vs_ftp_in() 323 &to.ip, ntohs(port), &cp->vaddr.ip, 0); in ip_vs_ftp_in()
|
D | ip_vs_proto_udp.c | 138 csum_fold(ip_vs_check_diff4(oldip->ip, newip->ip, in udp_fast_csum_update() 160 csum_fold(ip_vs_check_diff4(oldip->ip, newip->ip, in udp_partial_csum_update() 226 udph->check = csum_tcpudp_magic(cp->vaddr.ip, in udp_snat_handler() 227 cp->caddr.ip, in udp_snat_handler() 302 udph->check = csum_tcpudp_magic(cp->caddr.ip, in udp_dnat_handler() 303 cp->daddr.ip, in udp_dnat_handler()
|
/net/sunrpc/ |
D | svcauth_unix.c | 111 static inline int hash_ip(__be32 ip) in hash_ip() argument 113 int hash = (__force u32)ip ^ ((__force u32)ip>>16); in hash_ip() 117 static inline int hash_ip6(struct in6_addr ip) in hash_ip6() argument 119 return (hash_ip(ip.s6_addr32[0]) ^ in hash_ip6() 120 hash_ip(ip.s6_addr32[1]) ^ in hash_ip6() 121 hash_ip(ip.s6_addr32[2]) ^ in hash_ip6() 122 hash_ip(ip.s6_addr32[3])); in hash_ip6() 303 struct ip_map ip; in ip_map_lookup() local 306 strcpy(ip.m_class, class); in ip_map_lookup() 307 ipv6_addr_copy(&ip.m_addr, addr); in ip_map_lookup() [all …]
|
/net/bridge/netfilter/ |
D | ebt_among.c | 18 const char *mac, __be32 ip) in ebt_mac_wormhash_contains() argument 33 if (ip) { in ebt_mac_wormhash_contains() 37 if (p->ip == 0 || p->ip == ip) in ebt_mac_wormhash_contains() 44 if (p->ip == 0) in ebt_mac_wormhash_contains()
|
/net/ipv4/ |
D | ipconfig.c | 1444 char *cp, *ip, *dp; in ip_auto_config_setup() local 1466 ip = addrs; in ip_auto_config_setup() 1467 while (ip && *ip) { in ip_auto_config_setup() 1468 if ((cp = strchr(ip, ':'))) in ip_auto_config_setup() 1470 if (strlen(ip) > 0) { in ip_auto_config_setup() 1471 DBG(("IP-Config: Parameter #%d: `%s'\n", num, ip)); in ip_auto_config_setup() 1474 if ((ic_myaddr = in_aton(ip)) == ANY) in ip_auto_config_setup() 1478 if ((ic_servaddr = in_aton(ip)) == ANY) in ip_auto_config_setup() 1482 if ((ic_gateway = in_aton(ip)) == ANY) in ip_auto_config_setup() 1486 if ((ic_netmask = in_aton(ip)) == ANY) in ip_auto_config_setup() [all …]
|
D | arp.c | 963 __be32 ip = ((struct sockaddr_in *)&r->arp_pa)->sin_addr.s_addr; in arp_req_set_public() local 975 if (pneigh_lookup(&arp_tbl, net, &ip, dev, 1) == NULL) in arp_req_set_public() 986 __be32 ip; in arp_req_set() local 993 ip = ((struct sockaddr_in *)&r->arp_pa)->sin_addr.s_addr; in arp_req_set() 997 struct flowi fl = { .nl_u = { .ip4_u = { .daddr = ip, in arp_req_set() 1028 neigh = __neigh_lookup_errno(&arp_tbl, &ip, dev); in arp_req_set() 1059 __be32 ip = ((struct sockaddr_in *) &r->arp_pa)->sin_addr.s_addr; in arp_req_get() local 1063 neigh = neigh_lookup(&arp_tbl, &ip, dev); in arp_req_get() 1080 __be32 ip = ((struct sockaddr_in *) &r->arp_pa)->sin_addr.s_addr; in arp_req_delete_public() local 1084 return pneigh_delete(&arp_tbl, net, &ip, dev); in arp_req_delete_public() [all …]
|
/net/irda/ |
D | parameters.c | 420 arg.ip = va_arg(args, __u32 *); in irda_param_unpack() 421 *arg.ip = buf[n++]; in irda_param_unpack() 424 arg.ip = va_arg(args, __u32 *); in irda_param_unpack() 425 *arg.ip = get_unaligned((__u16 *)(buf+n)); n+=2; in irda_param_unpack() 428 arg.ip = va_arg(args, __u32 *); in irda_param_unpack() 429 *arg.ip = get_unaligned((__u32 *)(buf+n)); n+=4; in irda_param_unpack()
|