Home
last modified time | relevance | path

Searched refs:udph (Results 1 – 7 of 7) sorted by relevance

/external/wpa_supplicant_8/src/ap/
Dfils_hlp.c162 struct udphdr *udph; in fils_dhcp_handler() local
254 sizeof(*iph) + sizeof(*udph) + (end - pos) + 2); in fils_dhcp_handler()
264 iph->tot_len = htons(sizeof(*iph) + sizeof(*udph) + (end - pos)); in fils_dhcp_handler()
270 udph = wpabuf_put(resp, sizeof(*udph)); in fils_dhcp_handler()
271 udph->uh_sport = htons(DHCP_SERVER_PORT); in fils_dhcp_handler()
272 udph->uh_dport = htons(DHCP_CLIENT_PORT); in fils_dhcp_handler()
273 udph->uh_ulen = htons(sizeof(*udph) + (end - pos)); in fils_dhcp_handler()
274 udph->uh_sum = htons(0x0000); /* TODO: calculate checksum */ in fils_dhcp_handler()
483 const struct udphdr *udph; in fils_process_hlp_udp() local
486 if (len < sizeof(*iph) + sizeof(*udph)) in fils_process_hlp_udp()
[all …]
/external/linux-kselftest/tools/testing/selftests/networking/timestamping/
Dtxtimestamp.c337 struct udphdr *udph; in do_test() local
354 udph = (void *) buf + off; in do_test()
355 udph->source = ntohs(9000); /* random spoof */ in do_test()
356 udph->dest = ntohs(dest_port); in do_test()
357 udph->len = ntohs(sizeof(*udph) + cfg_payload_len); in do_test()
358 udph->check = 0; /* not allowed for IPv6 */ in do_test()
/external/iputils/Modules/
Dpg3.c243 struct udphdr *udph; in fill_packet() local
258 udph = (struct udphdr*)skb_put(skb, sizeof( struct udphdr)); in fill_packet()
267 udph->source= htons(9); in fill_packet()
268 udph->dest= htons(9); in fill_packet()
269 udph->len= htons(datalen+8); /* DATA + udphdr */ in fill_packet()
270 udph->check=0; /* No checksum */ in fill_packet()
/external/toybox/toys/pending/
Ddhcp.c170 struct udphdr udph; member
661 if (bytes < (int) (sizeof(packet.iph) + sizeof(packet.udph))) { in read_raw()
674 || packet.udph.dest != htons(DHCPC_CLIENT_PORT) in read_raw()
675 || ntohs(packet.udph.len) != (uint16_t)(bytes - sizeof(packet.iph))) { in read_raw()
687 packet.iph.tot_len = packet.udph.len; in read_raw()
688 check = packet.udph.check; in read_raw()
689 packet.udph.check = 0; in read_raw()
694 memcpy(&state->pdhcp, &packet.dhcp, bytes - (sizeof(packet.iph) + sizeof(packet.udph))); in read_raw()
699 return bytes - sizeof(packet.iph) - sizeof(packet.udph); in read_raw()
749 packet.udph.source = htons(DHCPC_CLIENT_PORT); in send_raw()
[all …]
Ddhcpd.c164 struct udphdr udph; member
170 struct udphdr udph; member
884 packet.udph.source = htons(gconfig.port); //SERVER_PORT in send_packet6()
885 packet.udph.dest = gstate.client_port; //CLIENT_PORT in send_packet6()
886 packet.udph.len = htons(sizeof(dhcp6_raw_t) - sizeof(struct ip6_hdr) - padding); in send_packet6()
887 packet.iph.ip6_ctlun.ip6_un1.ip6_un1_plen = htons(ntohs(packet.udph.len) + 0x11); in send_packet6()
888 packet.udph.check = dhcp_checksum(&packet, sizeof(dhcp6_raw_t) - padding); in send_packet6()
890 packet.iph.ip6_ctlun.ip6_un1.ip6_un1_plen = packet.udph.len; in send_packet6()
936 packet.udph.source = htons(gconfig.port);//SERVER_PORT in send_packet()
937 packet.udph.dest = gstate.client_port; //CLIENT_PORT in send_packet()
[all …]
Ddhcp6.c114 struct udphdr udph; member
623 if (ntohs(mymsg->udph.dest) == 546 && in dhcp6_main()
/external/wpa_supplicant_8/src/common/
Ddhcp.h43 struct udphdr udph; member