[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [patch #6760] Ping calculates incorrect checksum
From: |
Robert Sprowson |
Subject: |
[lwip-devel] [patch #6760] Ping calculates incorrect checksum |
Date: |
Mon, 02 Mar 2009 07:59:48 +0000 |
User-agent: |
Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1) |
Follow-up Comment #2, patch #6760 (project lwip):
I'm not sure the patch, as checked in, works.
The problem is that callers to ping_prepare_echo already add on the
sizeof(icmp_echo_hdr) so there's no need to calculate data_len as it's known
at compile time.
Say PING_DATA_SIZE = 64, the ICMP header size is 20 bytes (or whatever it
is).
We used to do
fill 20 byte header with stuff
64 bytes of alphabet
checksum 84 bytes
Now we do
fill 20 byte header with stuff
44 bytes of alphabet
checksum 84 bytes still
Sprow.
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/patch/?6760>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
[lwip-devel] Re: [patch #6760] Ping calculates incorrect checksum, Sprow, 2009/03/02
[lwip-devel] [patch #6760] Ping calculates incorrect checksum, Sprow, 2009/03/02