]> git.ipfire.org Git - thirdparty/mtr.git/commit
mtr-packet: TCP and SCTP probes
authorMatt Kimball <matt.kimball@gmail.com>
Tue, 20 Dec 2016 18:09:29 +0000 (10:09 -0800)
committerMatt Kimball <matt.kimball@gmail.com>
Tue, 20 Dec 2016 18:09:29 +0000 (10:09 -0800)
commitfcda9e8b82ca354049fa0ee9cfcb2eaaae623ee0
tree5b2cc01778e2b05085a3948452572e09e9413670
parent560e6802c1c82357c30057d55a76ebd3ade51146
mtr-packet: TCP and SCTP probes

Added support for generating probes using TCP or SCTP, for both
IPv4 and IPv6.  These protocols require that we create a unique
socket for each probe and watch for either a TTL expiration of
the initial packet sent during a connection attempt from that
socket or for socket connection success.

We now allocate a unique port number or ICMP sequence ID when
a probe is created, rather than using the command token for this
purpose.  This relieves the calling application of the burden
of picking sensible command token values, and allows command
tokens values greater than 16 bits.  However, the existing mtr
code continues to use the same command tokens values it has
previously used as port numbers, so there is no difference when
the calling program is mtr.

Split mtr's command pipe handling out from net.c and into cmdpipe.c
in the interest of future maintainability.

Split probe.py's simple probes out from the individual protocol
test cases and into common code which can be used by many
protocol tests.
22 files changed:
Makefile.am
cmdpipe.c [new file with mode: 0644]
cmdpipe.h [new file with mode: 0644]
mtr-packet.8.in
net.c
net.h
packet/command.c
packet/construct_unix.c
packet/construct_unix.h
packet/deconstruct_unix.c
packet/deconstruct_unix.h
packet/probe.c
packet/probe.h
packet/probe_cygwin.c
packet/probe_unix.c
packet/probe_unix.h
packet/wait_unix.c
select.c
test/mtrpacket.py
test/packet_listen.c
test/param.py
test/probe.py