Subject: bin/9412: ping reports nonsensical ttl
To: None <gnats-bugs@gnats.netbsd.org>
From: Wolfgang Rupprecht <wolfgang@wsrcc.com>
List: netbsd-bugs
Date: 02/13/2000 13:51:57
>Number:         9412
>Category:       bin
>Synopsis:       ping -s1500 reports nonsensical ttl
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bin-bug-people (Utility Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Feb 13 13:51:00 2000
>Last-Modified:
>Originator:     Wolfgang Rupprecht
>Organization:
W S Rupprecht Computer Consulting, Fremont CA
>Release:        -current 2/2/2000
>Environment:
	
System: NetBSD capsicum.wsrcc.com 1.4S NetBSD 1.4S (WSRCC) #0: Sat Feb 12 20:14:21 PST 2000 wolfgang@capsicum.wsrcc.com:/v/src/netbsd/NetBSD-current/usr/src/sys/arch/i386/compile/WSRCC i386


>Description:
	ping -s1500 reports nonsensical ttl
>How-To-Repeat:

    Notice the "ttl=0"

    # ping -s 1500 scoville
    PING scoville.wsrcc.com (192.83.197.5): 1500 data bytes
    1508 bytes from 192.83.197.5: icmp_seq=0 ttl=0 time=0.781 ms
    1508 bytes from 192.83.197.5: icmp_seq=1 ttl=0 time=0.870 ms
    ^C
    ----scoville.wsrcc.com PING Statistics----
    2 packets transmitted, 2 packets received, 0.0% packet loss
    round-trip min/avg/max/stddev = 0.781/0.826/0.870/0.063 ms

    In contrast a shorter (non-fragmented) ping reports the correct 
    value, 255; 

    # ping -s 1400 scoville
    PING scoville.wsrcc.com (192.83.197.5): 1400 data bytes
    1408 bytes from 192.83.197.5: icmp_seq=0 ttl=255 time=0.664 ms
    1408 bytes from 192.83.197.5: icmp_seq=1 ttl=255 time=0.781 ms
    ^C
    ----scoville.wsrcc.com PING Statistics----
    2 packets transmitted, 2 packets received, 0.0% packet loss
    round-trip min/avg/max/stddev = 0.664/0.723/0.781/0.083 ms

>Fix:
    check the code to make sure that the first fragment is examined for
    the ttl information.

>Audit-Trail:
>Unformatted: