Add support for setting SO_MARK through --mark option.
This emulates the -m option for ping provided in iputils. When coupled
with iptables, this option provides a means of using source routing to
force probes through a consistent nexthop on multihomed systems.
aquerubin [Wed, 29 Jan 2014 00:50:06 +0000 (14:50 -1000)]
Restore the name resolver query order to their relative position in
/etc/resolv.conf (the IPv6 resolver patch I submitted earlier broke this
normal, expected behaviour). Ie. currently, IPv6 resolvers are always
queried before IPv4 resolvers regardless of their position in
resolv.conf.
Michal Sekletar [Tue, 24 Sep 2013 10:56:11 +0000 (12:56 +0200)]
dns: iterate over all configured nameservers
Previously if there were three nameservers configured and third one was
reachable via IPv6 we didn't sent query to it, since NSCOUNT6 was equal to
one. Clearly it was the original intention to sent query to all IPv6
nameservers.
core: introduce grace period
This patch was somehow lost. I wrote and included this for 0.81, but it was removed again in 0.82. This was before git, so things were a bit messy back then. Sorry.
Michal Sekletar [Tue, 17 Sep 2013 14:11:20 +0000 (16:11 +0200)]
core: introduce grace period
In report mode we break out from select loop immediately after we reach
maximum count of iterations. But we should wait for packets which are still on
the way.
In order to fix the issue we introduce grace period during which we don't send
out more packets but we just wait for responses which might be still on the way.
Markus Chou [Sat, 6 Jul 2013 17:01:10 +0000 (01:01 +0800)]
fix building on osx
On Linux, they use 'BIND_4_COMPAT' and #include <arpa/nameser_compat.h> in <arpa/nameser.h>
On OSX, if 'BIND_8_COMPAT' is #defined, <arpa/nameser_compat.h> is #included in <arpa/nameser.h>
rewolff [Tue, 18 Jun 2013 05:36:08 +0000 (22:36 -0700)]
Merge pull request #16 from rpwoodbu/fix_sizes
Convey static array sizes with a constant instead of manual immediate values.
Good work. You say "log scale" while it is quadratic. wouldn't
for (i=NUM_FACTORS-1,t=1.0;i>0;i--, t = t/2.5) factors[i] = t;
work better? (I'm away, I remember seeing factors 0.02 and 0.05 next to each other hence the 2.5 )
Vaibhav Bajpai [Sun, 5 May 2013 16:35:53 +0000 (18:35 +0200)]
when looping on a list of service names with --csv, do not exit on the first
failure; instead write the error on stderr, skip that service names and move
on to the next service name in the list
Vaibhav Bajpai [Sun, 5 May 2013 15:09:12 +0000 (17:09 +0200)]
added --filename=FILE option
service names read from this file are allocated in a linked list
multiple service names are only accepted with --csv flag
without --csv flag, the first service name is used
Vaibhav Bajpai [Sun, 5 May 2013 14:06:37 +0000 (16:06 +0200)]
updated --csv format: VERSION;TIMESTAMP;STATUS;HOSTNAME;TTL;ENDPOINT;ASN;PING(ms)
STATUS field is hardcoded to "OK" for now; not sure what "FAIL" would mean
Kyle J. McKay [Fri, 22 Feb 2013 16:51:59 +0000 (08:51 -0800)]
Support building on OS X
* Add support for new --without-glib configure option to disable
all use of glib (also requires --without-gtk to be effective).
This has the side effect of disabling the "mtr -z" functionality.
* Improve configure support for detecting which library to link
with, if any, to get the resolver functions.
* Do not define BIND_8_COMPAT when compiling for Darwin/OS X.
* Autoconfigure whether or not a suitable struct __res_state_ext
needs to be defined.
* If the arpa/nameser_compat.h header is available and usable,
include it immediately after arpa/nameser.h.
Instead of sending ICMP ECHO or UDP packets, this mode opens a TCP
connection to the port of choice (80 by default) and sets IP_TTL
or IPV6_UNICAST_HOPS to control the TTL of the outgoing SYN packet.
Instead of using ICMP ECHO sequence or UDP destination port, the
source port number is used to track how many hops away a router is.
For getting the final hop, sockets are left open until a timeout
is reached (10 seconds default) and a write is attempted as soon
as the socket becomes available for writing. Anything other than
a succesful write or a "Connection refused" error is ignored.
R.E. Wolff [Tue, 12 Feb 2013 08:26:45 +0000 (09:26 +0100)]
Modernize for current autoconf/automake.
Add 'foreign' option so automake doesn't insist on ChangeLog file.
added file added by rename in previous commit.
Travis Cross [Sat, 9 Feb 2013 09:48:52 +0000 (09:48 +0000)]
Use format +git:XXXXXXXX
The colon is kinder to Debian than a dash and seems stylistically
better. The dash feels as though it introduces another version level,
e.g. -rc1-alpha2. We could just do +gitXXXXXXXX but as git commit
hashes are in lowercase hexadecimal the result can be something really
ugly like +giteaf0cb71. It's also easier to select the commit hash
for a copy/paste operation when there is something to separate it.
Travis Cross [Sat, 9 Feb 2013 08:16:48 +0000 (08:16 +0000)]
Add git version handling to build system
When building from a git tree, the version number built into the
binary will be appended with +git-XXXXXXXX.
The base version number is stored in-tree in configure.in and is that
of the last tagged release. Presumably the git version is later than
the last tag, so we use '+git' rather than '-git' to produce the
correct the lexical sort order -- though of course the sort order
between any two git revisions can only be determined from the git tree
rather than from a lexical sort.