20 Nov 2006 02:16
Re: DHCP paket size udhcp 0.9.9-pre
Denis Vlasenko <vda.linux <at> googlemail.com>
2006-11-20 01:16:32 GMT
2006-11-20 01:16:32 GMT
On Saturday 18 November 2006 21:46, Jim Wright wrote:
> On Nov 18, 2006, at 1:55 PM, Denis Vlasenko wrote:
>
> >> The mail you cite above sounds like it's using the standalone version
> >> and not the busybox version. Please clarify.
>
> From what I can tell, this was from the busybox version.
>
>
> > I just checked. We emit correctly sized packets.
>
> Are these correctly sized packets now less than 576 bytes? I tested
> here with Busybox 1.0 and 1.2.1, packet sizes from both versions were
> 590 bytes, which is causing these packets to be discarded by my ISP.
Okay. udhcpc sends packets using this code
(the only place where I see sendto() in udhcp subdirectory):
int udhcp_raw_packet(struct dhcpMessage *payload,
uint32_t source_ip, int source_port,
uint32_t dest_ip, int dest_port, uint8_t *dest_arp, int ifindex)
{
int fd;
int result;
struct sockaddr_ll dest;
struct udp_dhcp_packet packet;
...
result = sendto(fd, &packet, sizeof(struct udp_dhcp_packet), 0,
(struct sockaddr *) &dest, sizeof(dest));
(Continue reading)
RSS Feed