summaryrefslogtreecommitdiffstats
path: root/usr.sbin/tcpdump/print-iapp.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Rework UDP parsing, particularly around IP addresses.dlg2018-07-061-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This originally started as trying to put a consistent space between the UDP header information and the payload parsing, but while doing that I noticed inconsistent IPv4 vs IPv6 handling. Apart from the default "srcip.srcport > dstip.dstpor" output, all the other places that IP addresses were printed assumed IPv4. It looks like it is possible that udp_print() can be called without an IP header, which made these blind IPv4 prints turn into NULL derefs. This fixes the problem above by only having a single place that prints the addresses out, and makes sure to get the difference between IPv4, IPv6 and no IP correct. This changes how the checksum is calculated. It incrementally builds the UDP checksum by feeding the IPv4 and v6 addresses in separately, then using common code for the rest of the pseudo header and actual payload. Lastly, this does make printing the space between the UDP header and its payload consistent. The UDP code is now responsible for adding a space after itself so the payload parsers don't have to. They got it wrong in some cases anyway, so this should be a lot more uniform. help and ok sthen@
* Replace <sys/param.h> with <limits.h> and other less dirty headers wherederaadt2015-01-161-2/+1
| | | | | | | | | possible. Annotate <sys/param.h> lines with their current reasons. Switch to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where sensible to avoid pulling in the pollution. These are the files confirmed through binary verification. ok guenther, millert, doug (helped with the verification protocol)
* No use for <netinet/in_systm.h> nor <netinet/tcpip.h>.mpi2014-08-141-2/+1
|
* add whitespacereyk2006-03-101-2/+2
|
* Update my e-mail address in the copyright statement, no binary changes.reyk2005-12-181-2/+2
|
* add printer for IAPP and hostapd(8) messagesreyk2005-11-221-0/+107
ok canacar@, tested by aanriot@ and others