	@(#)RELEASE_NOTES       e07@nikhef.nl (Eric Wassenaar) 991603

	URL	ftp://ftp.nikhef.nl/pub/network/traceroute.tar.Z
	URL	http://www.nikhef.nl/user/e07

yymmdd		Description of changes per release
CHANGES		Changes with respect to original utility
TODO		Things that still need to be done
WISHLIST	Wishes expressed by various people
NOTES		Important issues to keep in mind

# ----------------------------------------------------------------------
# Description of changes per release
# ----------------------------------------------------------------------

991603
	Fix potential buffer overflow problem.
		Avoid excessively long strings during AS lookups.
		Reported by John Halperin <jxh@MAILBOX.SLAC.Stanford.EDU>
	Miscellaneous changes.
		Add the package name when printing the version number.
		Requested by Mike Sweger <mikesw@whiterose.net>

990522
	Minor portability changes.
		AIX needs <sys/select.h>
		Reported by Andreas Ley <andy@rz.uni-karlsruhe.de>
	There are no functional changes in this release.

990517
	Fix bug in rtt reporting.
		Certain ranges of rtt values were printed incorrectly.
		Noted by Les Cottrell <cottrell@slac.stanford.edu>

990511
	Minor portability changes.
		Solaris 2.7 defines `ipaddr_t'. Can you believe it.
		Fix glitch for bsdi.
		Noted by Paul Eggert <eggert@twinsun.com>
	There are no functional changes in this release.

990207
	4.4BSD raw IP options fix.
		As the IP options buffer is explicitly constructed as
		part of the raw IP packet, the setsockopt() call to
		pass the options to the kernel is redundant.
		Whereas on linux 2.0.* kernels this would be ignored,
		it will cause failures on 2.1.* and 2.2.* kernels.
		Reported by Martin Mares <mj@ucw.cz>

	Linux socket options fix.
		On the linux platform, the SO_xxx socket option codes
		are not binary disjunct as they are on other platforms.
		Reported by Martin Mares <mj@ucw.cz>

	Don't mask network addresses.
		Full IP addresses can be presented to whois servers
		that conform to the RIPE181/RPSL standard database
		format, allowing for CIDR addresses. This is now the
		default. Setting the flag AS_NETMASK in "aslookup.h"
		forces (non-CIDR) network addresses to be computed.

	Allow default whois server host.
		In the "aslookup.h" configuration file you can now
		define a default whois server which will be queried
		if neither the -h command line option is given nor
		the AS_SERVER_HOST environment variable is set.

980831
	Raw IP portability fix.
		The platforms which require the entire raw IP output
		packet to be constructed in network byte order, also
		return a raw IP input packet in network byte order.
		Most other platforms adopt the BSD implementation
		which handles some fields in machine byte order, and
		performs the htons()/ntohs() conversion in the kernel.

980828
	Linux raw ip fix.
		All fields in the user-supplied raw ip packet must be
		in network order instead of host order.
		Not sure whether this has always been the case.
		This is necessary for ip_off with the IP_DF bit set,
		in order to get the MTU discovery to work properly.
		It seems that the kernel always recomputes ip_len,
		regardless of what was specified in the raw packet.
	Linux portability fix.
		Whether the checksum in the struct ip is defined as
		ip_sum or ip_csum does not seem to depend on the
		kernel version after all. Assume it is ip_csum.
		This is probably the case for non-glibc versions.
		One can now overrule this via a flag in the Makefile.
	The linux glibc chicken-and-egg problem.
		If you have a __GLIBC__ version it would have been safe
		to predefine _BSD_SOURCE so that <features.h> can select
		the proper symbols such as __USE_BSD and __FAVOR_BSD.
		However, __GLIBC__ does not seem to be defined until the
		<features.h> file is invoked.
		To avoid utter ugliness, one currently has to define the
		symbol _BSD_SOURCE for those systems in the Makefile.
		Everything then compiles out of the box.

980228
	Linux portability fix.
		Certain distributions, most probably depending on the
		version of the glibc package, come with the real BSD
		netinet include files. This obsoletes the supplied
		linux.h file with portability hacks.
		One may have to define _BSD_SOURCE in the Makefile
		(which turns on the __FAVOR_BSD flag) to enforce this.

980102
	Linux portability fix.
		Well-known names of members in well-known structures
		keep changing all the time. Can you believe it.

971112
	HPUX portability fix.
		On the HP-UX 10.* platform, IP_TOS is now defined, but
		the corresponding setsockopt() always fails with either
		"Permission denied" or "Operation not supported".
		Set a new tos only if it was explicitly requested.
		Note that IPPROTO_RAW manipulation may now work,
		but it is not yet enabled by default on this platform.
		Problem reported by Andreas Luik <luik@isa.de>
	Minor portability changes.
		Identify SVR4 platforms depending on cpp symbols,
		which are different for various compilers.
		Necessary for properly defining RAW_IP_NET_ORDER on the
		little-endian machines that use this strategy.
		Mentioned by Andreas Luik <luik@isa.de>

971007
	Reconsider heuristic to determine BIND release.
		Some vendors still ship new BIND 4.9 releases that have
		the old struct ``state'' instead of ``__res_state''.
		This is now controlled via Makefile CONFIGDEFS.
	There are no functional changes in this release.

971006
	Linux portability fixes.
		The struct timeval passed to select() is modified to
		reflect the remaining time not slept. To keep the code
		portable, re-initialize the timeout in a fresh timeval.
	Backward compatibility fix.
		Some vendors still ship old BIND 4.9 releases that have
		the old struct ``state'' instead of ``__res_state''.
	Miscellaneous enhancements.
		Dump unexpected packets in a more descriptive way.
		Use same code as in the ping utility.
	Minor portability fixes.
		Properly identify certain platforms in port.h to avoid
		compiler warnings.
	Miscellaneous changes.
		Minor esthetical code changes.

970828
	Linux portability fixes.
		On certain platforms the standard include files expect
		the symbol __BSD_SOURCE whereas the compilers define
		the symbol  _BSD_SOURCE instead.
	Minor portability fixes.
		Use explicit casts for ntohs()/htons() in a few places
		to avoid compiler warnings on some platforms.
	There are no functional changes in this release.

970524
	More linux portability changes.
		Certain newer linux versions now define struct ip.
		These versions also seem to use the BSD44 strategy
		for IP options. This affects loose source routing.
		The -g option now works on those platforms.
		It remains unclear what the exact criteria are.
		Move include of linux.h to a more appropriate place.

961230
	Port to linux platform.
		Some additions were needed to the linux.h include file.
		This file is now invoked by port.h if appropriate.
		Tested by Larry Schwimmer <rosebud@cyclone.Stanford.EDU>
	Portability issues.
		Bypass bug in <netinet/ip.h> on alpha osf/1 platform.
		Properly identify Solaris x86 (little endian) platform.
		From Larry Schwimmer <rosebud@cyclone.Stanford.EDU>
	Extra safety checks.
		After a positive return from an ordinary gethostbyname
		or gethostbyaddr we cannot be absolutely sure that the
		size of the canonical h_name is within bounds.
		Make timeval subtraction more robust.
	Configurable defaults.
		Make various default values configurable in conf.h
	Miscellaneous changes.
		Attempt to further reduce lint clutter. It is difficult
		to eliminate this altogether. There are too many subtle
		differences between various platforms.

960301
	Cache nameserver lookups.
		DNS address-to-name translations are cached to avoid
		excessive DNS queries. Actually this is more important
		for ping than traceroute, but we can use the same code.
	Redesign AS-number lookup.
		Retrieve AS-number only from "route" objects in the
		database. If multiple objects exist, use the first one.
		Skip objects that have a too general CIDR assignment.
		Also avoid dummy AS0 entries.
		Include the first "descr" descriptive text, if present.
		(This should be done by making an explicit AS query).
	Miscellaneous changes.
		Change the field separator back from comma to (double)
		space. It would break certain scripts (prtraceroute)
		which depend on the correct syntax of the output.
	Portability fixes.
		Minor changes to run on SCO platforms.
		SCO/OS5 comes with its own version of in_cksum().
	Port to linux platform.
		Add compatibility definitions in separate linux.h
		header file. This file is not yet invoked, as it is
		untested so far.

951024
	Correct various misspellings.
		There are no functional changes in this release.

951017
	Enhance rtt statistics printout.
		Add the standard deviation to the statistics summary.
		Supply simple sqrt function to avoid linking with -lm.

951014
	Display per-hop min/avg/max rtt summary.
		New option -S to print a per-hop statistics summary.
		This suppresses the per-probe rtt and ttl reporting.
		Stop after detecting consecutive timeouts, which can
		be configured via the new -Q option.
	Miscellaneous changes.
		Ensure rtt values don't cause overflow. This limits
		their values to ~35 minutes. That seems sufficient.
		Improve readability of printout by inserting commas
		at appropriate places.

951008
	Allow setting of initial ttl.
		New option -i to set an arbitrary initial ttl value,
		which overrules the default starting value 1.
		Enforce constraints 1 <= min_ttl <= max_ttl <= 255.
		Will report ttl mismatch if set beyond destination.
	Improve interrupt handling.
		Perform synchronous instead of asynchronous interrupt
		handling when necessary. If we have an open connection
		to a whois server, interrupting at the wrong moment
		could cause the dialog to go out-of-phase.
		Requires redesign to make I/O routines restartable.
	Miscellaneous changes.
		Flush pending buffered output at appropriate moments.
		Terminate pending buffered output to stdout before
		issuing a message to stderr, to improve readability.
		Added the CHANGES section to this RELEASE_NOTES file.

951005
	Implement AS-number lookup.
		With the new -A option, the AS-number of the network
		address (not host address) for each hop is retrieved
		from the whois server specified by the new -h option.
		The connection to the server is kept open permanently
		if the new -k option is given. (Note that the server
		must support this as well; not all servers do).
	Customize AS-number lookup.
		To override the default settings, one can define the
		environment variables AS_SERVER_HOST, AS_SERVER_PORT,
		and AS_SERVER_OPTIONS. See aslookup.h for details.
		Command line options always take precedence.
	Add separate aslookup utility.
		A stand-alone utility aslookup can be compiled which
		looks up the AS-number for a dotted quad address, and
		the AS-number for all interfaces of a multi-homed host.
	Configurable default options.
		Use an environment variable TRACEROUTE_DEFAULTS to set
		default options and parameters. These are interpolated
		in front of the command line arguments before scanning.
		Syntax is the same as the command line syntax.
	Lookup network names.
		Display network names as returned via the BIND 4.9.3
		RFC 1101 compliant getnetbyaddr() in libresolv.a.
		Suggested by Paul Pomes <ppomes@qualcomm.com>
		The new option -N enables this feature. With BIND 4.8,
		getnetbyaddr() just consults the /etc/networks file.
	Miscellaneous changes.
		Restructure command line option handling.
	Major update of manual page.

950930
	Anticipate unexpected behavior of certain routers.
		Some machines fail to return code ICMP_UNREACH_PORT
		if they are specified as the target host. Assume we
		have reached the destination if we get a TIMXCEED
		from the address that we are tracing. Obviously this
		test must be skipped during loose source routing.
	Avoid potential alignment conflicts.
		Allocate socket addresses of type struct sockaddr_in
		instead of type struct sockaddr. The first one has
		stricter alignment restrictions, although they have
		the same size.
		This seems to solve, albeit not totally understood,
		a bus error problem which occurs only when traceroute
		is linked with the bind 4.9.3b24 libresolv.a on the
		machine of Paul Pomes <ppomes@qualcomm.com>
	Rigorously check command line parameters.
		Avoid bogus values which would cause problems later.
		Make sure the udp destination port stays in range.
	Miscellaneous changes.
		Minor code and lint cleanup.
		Added the NOTES section to this RELEASE_NOTES file.

950928
	Port to 4.4BSD platforms.
		On 4.4BSD based platforms, the entire raw IP header
		must be filled in, whereas on traditional platforms
		certain fields are stored by the kernel.
		The IP options buffer must also be supplied, whereas
		on traditional platforms the kernel will insert it.
		Besides, we must do the first hop routing ourselves.
	Adapt MTU discovery algorithm.
		Properly take into account an extra IP options buffer
		in the total ip packet size. Also report the extended
		size in the announcement message.
	Attempt to adapt IP options construction.
		Compute the exact IP options buffer length, instead of
		always using the maximum size. However, several systems
		cannot handle this properly (e.g. HPUX), so revert back
		to use the maximum size.
	Miscellaneous changes.
		Extend socket send buffer if IP options are present.
		Rename SYSV_UDPPROTO compile switch to NO_RAW_IP.
		Use IP_TOS (if available) in case of NO_RAW_IP.
	Refine round-trip time reporting.
		Print rtt appropriately in fractional milliseconds.
		The number of printed digits depends on the value.
		(Example:  0.123 ms  1.23 ms  12.3 ms  123 ms).
		This can be useful for measuring very fast links,
		but should be taken with a grain of salt on systems
		with a poor clock resolution.

950918
	Disable all reverse DNS lookups in numeric mode.
		The -n flag now also prevents a reverse lookup of a
		numeric dotted quad address given on the command line.
		This avoids a potential annoying nameserver timeout.
		Requested by Geert Jan de Groot <geertj@ripe.net>
		Note that this applies to both the destination host
		and the gateways specified with the -g flag. In the
		latter case, the -n flag must precede the -g flag.

950808
	Raw IP portability fix.
		Certain platforms require the entire raw IP packet
		to be constructed in network byte order, whereas
		most other platforms adopt the BSD implementation
		which takes some fields in machine byte order.
		First mentioned for little-endian Solaris 2.x
		machines by Andreas Luik <luik@isa.de>
	Minor changes.
		Print more verbose description of bad icmp reply
		packets of type destination unreachable.
	Bug fix.
		An incorrect source address was printed for bad
		icmp reply packets.

950805
	Recognize new ICMP codes.
		Some new ICMP_UNREACH subcodes are now detected.
		The latest codes are defined by RFC 1812.
	Redesign internal ICMP packet type passing.
		Cannot use original type/code any more because of
		overlapping range. Define unique internal values.

941215
	Anticipate unexpected behavior of certain routers.
		Some routers (Wellfleet) return code ICMP_UNREACH_PORT
		if they are specified as loose source route gateways.
		We cheat and ignore this status in case it comes from
		any of the gateways given on the command line.
		Problem reported by Arif Diwan <adiwan@bbn.com>
	Keep track of all gateway addresses.
		Maintain list of all addresses of gateways hosts, just
		in case replies are sent from a different interface
		than was specified on the command line.
	Add the RELEASE_NOTES file to explain changes.

941119
	Adapt MTU handling for special platforms.
		Add MTU 1268 (unfragmented) for Apollo token ring.
		Apollo returns EMSGSIZE if the packet is too big to
		be fragmented, and EIO if fragmentation is disabled.
	Define TTL and MTU values in new conf.h header file.

941117
	Implement MTU discovery.
		New option -f to prevent IP fragmentation. This gives
		the possibility for MTU discovery. We use the full list
		of MTU values from RFC 1191, not only the suggested
		plateau values.
		Note that this will not work on those platforms which
		don't support the IPPROTO_RAW manipulation.
	Change command line specs.
		Optional packet size gives the size of the IP packet,
		instead of the size of the extra data buffer.

940711
	Add another known ttl value.
		Netware routers use ttl value 128.
		From Johann Haider <Johann.HAIDER@fortec.tuwien.ac.at>
	Delay printing of timeout asterisk.
		If the first probe fails due to timeout, but subsequent
		probes succeed, the timeout asterisk will be printed
		after the host name, to improve readability.
		From Johann Haider <Johann.HAIDER@fortec.tuwien.ac.at>

940706
	Support multi-homed destinations.
		New option -a to probe all destination addresses.
		Each pass can be terminated with Control_C.
		Requires some reshuffling of code.
	Special handling for multi-homed routers.
		New option -c to specify a delay in seconds to pause
		between sending probe packets. This may be necessary
		if the destination is a Cisco router which does not
		accept undeliverable packets in bursts.

940704
	Fix recv timeout bug.
		The situation where we are catching icmp reply packets
		that don't belong to us, would cause a recv retry with
		the original timeout value. If our own destinations
		don't reply at all, we would seem to hang forever.
	More portability fixes.
		Cannot rely on sizeof() for several structs on those
		platforms which don't have 16 or 32 bit integers.
	Miscellaneous minor changes.
		Remove own domain stripping in hostname printout.
		Delete hex dump of unwanted input packets.
	Adapt checksum algorithm to be more portable.

940629
	General portability fixes.
		Use ipaddr_t instead of u_long for IP addresses.
		Use predefined constants for fixed size entities.
		Add port.h and defs.h header files.
	Use various exit codes to indicate success or failure.
		They are defined in new exit.h header file.
	Define short resolver lookup delay.
		This avoids annoying nameserver timeouts.
 
930211
	Port to special platforms.
		Add code for those platforms which don't support the
		IPPROTO_RAW manipulation. We can send an udp packet,
		and request an explicit ttl value for the ip packet.
		This is necessary, and seems to work, for HPUX.

910223
	Pickup version with loose source route facility.
	Overhaul of entire code. Minor bugs fixed.

# ----------------------------------------------------------------------
# CHANGES
# ----------------------------------------------------------------------

o  Major code redesign
	Improve robustness, portability, readability, maintainability.
o  General portability fixes
	For platforms with 64-bit long integers and 32-bit integers,
	and platforms without 32-bit integers or 16-bit short integers.
o  Special platform support
	New strategy for platforms without raw ip support (hpux).
	On other platforms IP_HDRINCL interferes with LSRR (sgi).
o  Fix timeout handling
	Non-traceroute ICMP packets will no longer interfere.
o  Multi-homed destinations
	Probe all addresses of multi-homed destinations in succession.
o  MTU discovery
	Prevent ip fragmentation, and select new mtu sizes (RFC 1191).
o  Recognize various new ICMP codes.
	New ICMP types and UNREACH subcodes are dealt with (RFC 1812).
o  Better round-trip time reporting
	Fractional ms values, variable format (significant digits only).
o  Port to 4.4BSD platforms
	Requires special processing for IP_OPTIONS in raw ip packets.
	Requires to perform first-hop routing.
o  Recognize strange routers
	Some fail to return UNREACH_PORT if they are the target.
	Others falsely return UNREACH_PORT if they are LSRR gateways.
o  AS-number lookup from whois server
	Intelligence has been built in to keep the connection open.
o  Stand-alone aslookup utility
	AS for dotted quad, AS for all interfaces of multi-homed host.
o  Network name lookup
	The BIND 4.9.3 getnetbyaddr() is RFC 1101 compliant.
o  Customizing default options
	Environment variables can be used to preset often used options.
o  Initial ttl specification
	Allow setting of initial ttl to skip first few hops.
o  Display per-hop min/avg/max rtt summary
	Suppress per-probe report. Stop after consecutive timeouts.
	Include the standard deviation to the statistics summary.
o  Cache nameserver lookups
	Avoid multiple DNS queries for already known IP addresses.

# ----------------------------------------------------------------------
# TODO
# ----------------------------------------------------------------------

# ----------------------------------------------------------------------
# WISHLIST
# ----------------------------------------------------------------------

	Incorporate NANOG traceroute features.
		This version from Jamshid Mahdavi and Ehud Gavron has
		the following specials requested by NANOG operators:
		o  AS-number lookup (done)
		   Displays the autonomous system to which hops belong.
		   [The implementation is too simple and not robust.]
		   This is what the prtraceroute wrapper script does.
		   The feature has been added as of version 951005.
		o  SOA hostmaster lookup
		   Prints the hostmaster address as retrieved from the
		   SOA record of the zone to which hops belong.
		   Not sure whether this really should be a feature.
		o  Single hop statistics (done)
		   Shows min/avg/max statistics for the probes per hop.
		   This is actually what ping does.
		   The feature has been added as of version 951014.
		o  Port to VMS

# ----------------------------------------------------------------------
# NOTES
# ----------------------------------------------------------------------

	Packet size specification.
		The optional packet size specification on the command
		line defines the size of the probe packet *without* a
		possible options buffer.
		The (initial) actual size will automatically be extended
		in case loose source route gateway addresses are given.
		For MTU discovery, the total size including the options
		buffer would be necessary.
		However, as the packet travels past loose source route
		gateways, the options buffer shrinks as the gateways
		peel off their own address.
		Therefore, the packet size specification on the command
		line should be considered as the *minimum* size the
		probe packet must have.

