Subject: Re: CVS commit: src/sbin/ping
To: Perry E. Metzger <perry@piermont.com>
From: None <itojun@iijlab.net>
List: source-changes
Date: 04/15/2003 11:25:27
>> >> permit -s 0. from Maxim Konovalov
>> >What does it mean to use a 0 byte packet?
>> That just refers to the payload not the entire packet.
>Ah, and so it does.
value after -s indicates the length of "Data" portion in the
following diagram (echo request/reply format). therefore with "-s 0"
echo request packet will have no "Data" part.
itojun
from RFC792:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type | Code | Checksum |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Identifier | Sequence Number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Data ...
+-+-+-+-+-