Searched refs:iphdr (Results 1 – 7 of 7) sorted by relevance
| /xnu-11417.121.6/bsd/netinet/ |
| H A D | in_gif.c | 107 struct ip iphdr; /* capsule IP header, host byte ordered */ in in_gif_output() local 168 bzero(&iphdr, sizeof(iphdr)); in in_gif_output() 169 iphdr.ip_src = sin_src->sin_addr; in in_gif_output() 172 iphdr.ip_dst = sin_dst->sin_addr; in in_gif_output() 177 iphdr.ip_p = proto; in in_gif_output() 179 iphdr.ip_ttl = ip_gif_ttl; in in_gif_output() 180 iphdr.ip_len = m->m_pkthdr.len + sizeof(struct ip); in in_gif_output() 182 ip_ecn_ingress(ECN_NORMAL, &iphdr.ip_tos, &tos); in in_gif_output() 184 ip_ecn_ingress(ECN_NOCARE, &iphdr.ip_tos, &tos); in in_gif_output() 196 bcopy(&iphdr, mtod(m, struct ip *), sizeof(struct ip)); in in_gif_output()
|
| /xnu-11417.121.6/bsd/netinet6/ |
| H A D | ah_core.c | 570 struct ip iphdr; in ah4_calccksum() local 573 m_copydata(m, off, sizeof(iphdr), (caddr_t)&iphdr); in ah4_calccksum() 575 hlen = IP_VHL_HL(iphdr.ip_vhl) << 2; in ah4_calccksum() 577 hlen = iphdr.ip_hl << 2; in ah4_calccksum() 579 iphdr.ip_ttl = 0; in ah4_calccksum() 580 iphdr.ip_sum = htons(0); in ah4_calccksum() 582 iphdr.ip_tos = 0; in ah4_calccksum() 584 iphdr.ip_off = htons(ntohs(iphdr.ip_off) & ip4_ah_offsetmask); in ah4_calccksum() 585 (algo->update)(&algos, (caddr_t)&iphdr, sizeof(struct ip)); in ah4_calccksum() 688 hdrtype = (iphdr.ip_p) & 0xff; in ah4_calccksum()
|
| /xnu-11417.121.6/bsd/net/ |
| H A D | if_ports_used.c | 1510 struct ip iphdr = {}; in if_ports_used_match_mbuf() local 1514 error = mbuf_copydata(m, 0, sizeof(struct ip), &iphdr); in if_ports_used_match_mbuf() 1521 npi.npi_local_addr_in = iphdr.ip_dst; in if_ports_used_match_mbuf() 1522 npi.npi_foreign_addr_in = iphdr.ip_src; in if_ports_used_match_mbuf() 1527 if ((ntohs(iphdr.ip_off) & ~(IP_DF | IP_RF)) && in if_ports_used_match_mbuf() 1528 (ntohs(iphdr.ip_off) & IP_OFFMASK) != 0) { in if_ports_used_match_mbuf() 1533 if ((iphdr.ip_hl << 2) < pkt_data_len) { in if_ports_used_match_mbuf() 1534 pkt_data_len -= iphdr.ip_hl << 2; in if_ports_used_match_mbuf() 1539 pkt_proto = iphdr.ip_p; in if_ports_used_match_mbuf() 1541 switch (iphdr.ip_p) { in if_ports_used_match_mbuf() [all …]
|
| H A D | if_bridge.c | 7940 struct ip *iphdr; 7947 iphdr = (struct ip *)(void *)(header + sizeof(struct ether_header)); 7948 bcopy(&iphdr->ip_dst, &dst, sizeof(dst)); 8022 struct ip *iphdr; 8033 iphdr = (struct ip *)(header + sizeof(*eh)); 8034 ip_header_len = IP_VHL_HL(iphdr->ip_vhl) << 2; 8039 bcopy(&iphdr->ip_src, &ip, sizeof(ip)); 8046 if (ip.s_addr == 0 && iphdr->ip_p == IPPROTO_UDP) { 9433 struct ip *iphdr; 9435 iphdr = (struct ip *)(header + sizeof(struct ether_header)); [all …]
|
| H A D | bpf.c | 3829 struct ip iphdr; in get_ip_trunc_len() local 3830 err = bpf_copydata(pkt, off, sizeof(struct ip), &iphdr); in get_ip_trunc_len() 3837 iplen = (uint16_t)(iphdr.ip_hl << 2); in get_ip_trunc_len() 3842 proto = iphdr.ip_p; in get_ip_trunc_len()
|
| H A D | pf.c | 6463 struct ip *__single iphdr = pbuf->pb_data; in pf_test_dummynet() local 6464 NTOHS(iphdr->ip_len); in pf_test_dummynet() 6465 NTOHS(iphdr->ip_off); in pf_test_dummynet()
|
| /xnu-11417.121.6/bsd/skywalk/nexus/flowswitch/ |
| H A D | fsw_dp.c | 3647 update_flow_info(struct __kern_packet *pkt, void *iphdr, void *tcphdr, uint16_t payload_sz) in update_flow_info() argument 3652 void *, iphdr, void *, tcphdr, uint16_t, payload_sz); in update_flow_info() 3653 pkt->pkt_flow_ip_hdr = (mach_vm_address_t)iphdr; in update_flow_info()
|