guy [Thu, 1 Feb 2007 02:15:19 +0000 (02:15 +0000)]
Don't assume "echo -n" strips off the newline; it doesn't, if the echo
command behaves like the SV echo. Instead, strip off the newline with
"tr -d '\012'".
guy [Sun, 14 Jan 2007 21:29:22 +0000 (21:29 +0000)]
From Kevin Steves:
0) use TTEST/TCHECK macros vs. snapend comparisons
1) when -vvv display PAD and END options
(multiple PAD options are summarized)
2) change a trunc string from bootp to rfc1048 because I think that is
what is intended (matches trunc label)
hannes [Tue, 12 Dec 2006 14:31:51 +0000 (14:31 +0000)]
apply some heuristics to detect MPLS ICMP extension headers because
not all implementations correctly set the length field in the
ICMP header as per draft-bonica-internet-icmp-08.
if the length field is not set then simply check the checksum.
hannes [Tue, 12 Dec 2006 10:48:43 +0000 (10:48 +0000)]
rework on the ICMP MPLS extension code:
- preserve the snapend pointer as it may get overwritten by calling the IP printer
- protect against infinite loops inside the MPLS extension printer.
- detect present of an MPLS extension header by introducing a length field to the ICMP header
as per draft-bonica-internet-icmp-08.
guy [Sun, 12 Nov 2006 22:21:44 +0000 (22:21 +0000)]
For OPT resource records, the class field is used as a length, so, if one
happens to be in an mDNS packet, we don't split it into a class and a
"cache flush" flag.
guy [Fri, 10 Nov 2006 03:18:21 +0000 (03:18 +0000)]
The topmost bit in the class field isn't a "cache flush" flag in mDNS
queries. Display that bit correctly (as per Marc Krochmal's request).
In mDNS, the topmost bit of the class field should be handled the same
way regardless of the value of the lower 15 bits, and *vice versa* -
they're independent fields.
hannes [Thu, 2 Nov 2006 09:05:23 +0000 (09:05 +0000)]
from Gerrit Renker <[email protected]>:
add support for variable-length checksum in DCCP, as per section 9 of RFC 4340.
remove duplicated code in dccp6_cksum (which just repeated the code of in_cksum
fix a bug in dccp.h -- the fields of CCVAL and CSCOV were swapped (see section 5.1 of RFC 4340)
fix a typo in the display of incorrect checksums
old output `cksum xDEAD (incorrect (-> xBEEF)',
new output `cksum xDEAD (incorrect -> xBEEF)'
guy [Wed, 25 Oct 2006 22:02:36 +0000 (22:02 +0000)]
From Shinsuke Suzuki:
Some of the options in print-dhcp6.c are declared as
"unassigned ones". but it is no longer true due to an
IETF standardization activities.
Here's the patch to catch up with the latest IANA
assignment, including an removal of the old Prefix-
Delegation option used in the NTT-communications.
(AFAIK they no longer uses this old option).
guy [Wed, 13 Sep 2006 06:31:11 +0000 (06:31 +0000)]
Cast "sizeof" to a "u_int"; it's not guaranteed to be "int" in size (it
could be "long", for example, and probably *is* "long" on LP64
platforms), so you can't print it with "%u", but, in this particular
case, it's going to fit in a 32-bit quantity.
hannes [Tue, 5 Sep 2006 15:50:26 +0000 (15:50 +0000)]
-rework the OSPFv3 printer:
-share the grace and TE LSA printer with the OSPFv2 printer
-change to multiple line output (behind vflag)
-unambiguate datastructures such that the OSPFv3 printer can
include OSPFv2 header files.
guy [Tue, 13 Jun 2006 22:21:38 +0000 (22:21 +0000)]
From NetBSD:
revision 1.7
date: 2006/03/25 11:43:53; author: rpaulo; state: Exp; lines: +23 -3
PR 13604: detect and print correct information for 4.4BSD/NetBSD NFS
filehandles.
The heuristic may or may not be wrong, but no one replied in the
tcpdump-workers mailing list.
Extraction of the fsid information contributed by Chuck Silvers.
Discussed with Chuck Silvers.
----------------------------
revision 1.6
date: 2006/03/22 04:30:28; author: christos; state: Exp; lines: +4 -2
Coverity CID 563: Kill SUNOS3 case; it is dead code.
----------------------------
hannes [Thu, 18 May 2006 08:23:26 +0000 (08:23 +0000)]
continue work on the 802.3AH printer:
-add support for link-event TLVs
-clean up some confusion between shared and unshared
TLV formats.
-do per-TLV hexdumping
guy [Fri, 12 May 2006 02:14:55 +0000 (02:14 +0000)]
"ether.h" defines more than we need, and, on some platforms, redefines
ether_header (which is one of the things we don't need). Just define
ETHER_ADDR_LEN to 6 if it's not defined - it can't be anything but 6.
guy [Fri, 12 May 2006 01:45:19 +0000 (01:45 +0000)]
From Don Ebright: some compilers, such as the AIX compiler, reject a
comma at the end of the last member of an enum (the C language spec
doesn't say it's valid to have one there).
guy [Fri, 7 Apr 2006 08:36:03 +0000 (08:36 +0000)]
Extract "firstPacket" into a variable with EXTRACT_32BITS(), and use
that whenever we print its value, so that we always get it in the right
byte order.
add support for the the post-rotate -z flag (to be used in
conjunction with -C or -G) which can be used to specify a command tcpdump
should execute on each savefile after it's been rotated
for example to compress a capture file.
hannes [Mon, 13 Feb 2006 18:59:29 +0000 (18:59 +0000)]
clean up the bootp printer:
-print option/tag numbers and len
-change the tokenstring such that the most common options are human-readable
-add support for option 82 (Agent-ID) suboptions
-make more use ok tok2str() rather thane private lookalives
hannes [Thu, 9 Feb 2006 21:16:47 +0000 (21:16 +0000)]
move the crc10 verification to a new file checksum.c (will add other checksumming routines later to this file), init shred checksumming tables with init_checksum(), assume network byte order for tag correlation ID in the ATM OAM cell printer
hannes [Thu, 9 Feb 2006 20:33:49 +0000 (20:33 +0000)]
move the crc10 verification to a new file checksum.c (will add other checksumming routines later to this file), init shred checksumming tables with init_checksum(), assume network byte order for tag correlation ID in the ATM OAM cell printer