lukem
9c1945664c
Remove the \n and tabs from the __COPYRIGHT() strings.
...
Tweak to use a consistent format.
2008-07-21 13:36:57 +00:00
christos
c709bea66c
Use htonl like ping/traceroute6 do, from Markus Mayer
2008-07-17 19:23:17 +00:00
christos
53bc7350a9
PR/39157: Markus Mayer: traceroute not 64 bit aware (struct timeval issue)
2008-07-16 21:34:16 +00:00
seanb
56143d3b3c
- Set progname before dereference.
2008-01-16 19:18:06 +00:00
perry
4d096031f0
replace instances of __attribute__((__packed__)) with __packed
2007-12-15 16:03:29 +00:00
scw
cf78539af7
Undo a workaround for an old SH5 toolchain bug.
...
No functional change.
2007-04-08 09:43:51 +00:00
elad
1232ea27c4
PR/18906: roskens at elfin dot net: misc. select() to poll() updates.
...
Adapted to -current by myself, thanks for the patch!
2006-10-07 17:27:57 +00:00
elad
e35f123530
PR/19069: Jun-ichiro itojun Hagino: traceroute(8) and traceroute6(8) can
...
send packet to udp port 0, which is illegal
2006-10-07 10:23:33 +00:00
elad
06a208eecf
Move socket calls way up and drop root privileges sooner.
2006-09-24 11:34:35 +00:00
rpaulo
134b1ef326
Add missing coma.
2006-05-31 20:23:52 +00:00
rpaulo
fc5eb63af6
It doesn't make sense to print the MPLS ttl here.
...
While here, make the output look like Cisco IOS. Suggested by Mihai CHELARU.
2006-05-31 20:22:52 +00:00
mrg
0c37c63edc
change (mostly) int to socklen_t. GCC 4 doesn't like that int and
...
socklen_t are different signness.
2006-05-09 20:18:05 +00:00
rpaulo
39c9cdcdbf
Show MPLS ICMP extensions. Only available if -M is passed.
...
Example:
RC02-02 (195.245.142.66) 45.707 ms 20.418 ms 34.042 ms [MPLS: label: 515, exp: 0x0, ttl: 1]
gr1-p340.attga.ip.att.net (12.123.20.190) 241.878 ms 251.945 ms [MPLS: label: 32133, exp: 0x0, ttl: 1]
Based on PR 22523: By Jesper Skriver (updated by ww@parc.styx.org and Mihai
CHELARU).
Things not in the PR that I changed/added:
* changed exp and label to lower case
* added ttl (probably not worth it but who knows..)
* KNF/style/indent
* C99 uintXX_t
2006-02-17 21:31:18 +00:00
itojun
2a4c071a4f
do not disclose endian/pid. henning@openbsd
2004-04-22 01:41:22 +00:00
jmmv
b635f565e7
Homogenize usage messages: make the 'usage' word all lowercase, as this seems
...
to be the most common practice in our tree.
2004-01-05 23:23:32 +00:00
itojun
3d2b0dbc0e
strncpy -> strlcpy
2003-05-17 18:13:55 +00:00
itojun
f2bfdc2f65
traceroute.c doesn't use savestr()
2003-05-15 00:04:16 +00:00
itojun
07780ab297
die if strdup failure
2002-11-16 15:43:52 +00:00
itojun
240664d004
strto* audit.
2002-11-16 03:36:17 +00:00
itojun
901d58cdce
poll.h, not sys/poll.h
2002-10-01 05:56:12 +00:00
mycroft
36b12b30ec
select() -> poll()
2002-09-18 23:33:37 +00:00
itojun
072e5e6887
it is no use to do SO_DONTROUTE on receive socket. stevesk@openbsd
2002-08-12 02:51:07 +00:00
itojun
d36c8b47de
no need for struct timezone. From: Kevin Steves <kevin@atomicgears.com>
2002-08-09 02:57:09 +00:00
itojun
f34e694103
correct in_cksum2 for odd length case
2002-08-01 09:03:50 +00:00
itojun
80964024a7
kill register variable decls, they are meaningless these days
2002-08-01 09:02:18 +00:00
itojun
518af973ec
u_short cleansing (use u_int16_t where appropriate).
...
XXX in_cksum2 does not seem correct in odd length case
2002-08-01 08:41:32 +00:00
scw
4036c57dcb
Work-around an internal compiler error on the SuperH sh5 toolchain.
2002-07-11 20:07:07 +00:00
itojun
1fd7b003fa
it is highly unlikely that protocol # for ip/icmp to change. from deraadt.
2002-06-29 12:12:57 +00:00
itojun
c264025d4e
grab max hlim/ttl from kernel via sysctl. sync w/openbsd
2002-05-26 14:45:43 +00:00
yamt
59998d6154
check if timeout already expired before select.
...
from OpenBSD/FreeBSD.
2002-01-12 02:42:58 +00:00
atatat
f5d592cf44
Add support for printing the AS number associated with the address at
...
each hop.
2001-11-04 23:14:35 +00:00
yamt
76e9d7eb12
fix lsrr.
2001-10-09 12:43:37 +00:00
itojun
48110adac6
correct fd_set allocation. from deraadt
2001-01-12 18:53:20 +00:00
itojun
6626345485
avoid fd_set overflow. see openbsd select(2).
...
XXX should we use poll(2)?
2000-10-07 06:53:41 +00:00
sommerfeld
802499fd1c
Avoid using savestr() on something which will later be passed to
...
free(). Raised as a potential security issue on bugtraq. No actual
exploits known.
2000-09-30 12:44:37 +00:00
itojun
a58fc4d3b8
sync with latest libipsec/kernel.
2000-01-31 14:25:42 +00:00
sommerfeld
0cd03c86b4
Fix use of -I and -P at the same time by refactoring so there's only
...
one set of code which knows how to resize the packet.
Report when we shrink MTU because of an EMSGSIZE return; fix
formatting to let this not look ugly.
Add a few likely MTU's to the table (1480 and 1280).
2000-01-25 16:24:32 +00:00
itojun
e33da94c5b
configure IPsec policy on sending/receiving socket for bypassing IPsec.
...
If IPsec default policy is configured for destination
traceroute will never success (because encrypted icmp timexceeded
is unrecognizable).
1999-09-03 03:10:38 +00:00
kim
6f775308a6
Only require half of the responses to indicate that the destination is
...
unreachable. This makes traceroute exit when it encounters a Cisco, which
typically does not respond to every other probe (or so) when either there
is no route to the destionation or an access list is blocking the probes.
1999-06-19 05:07:44 +00:00
is
38f1211404
Add sanity check for MTU size in fragmentation required packets.
1999-06-16 20:43:48 +00:00
is
847d4766be
Factor out common code in the fragmentation required branch.
1999-06-16 20:10:07 +00:00
is
a11ec6ccb8
Don't forget to update the UDP length when changing the packet length.
...
Reported by Johan Danielsson in PR 7781; the fix is an updated version
(by the same person) of the patch in the PR.
1999-06-16 13:52:58 +00:00
is
6f6fd8467a
Cosmetics: a) add missing \n-s, b) this is ntohs, not htons, here.
1999-06-16 13:26:16 +00:00
tron
ab86ce8dab
Fix byte ordering problem on little endian systems. Patch supplied by
...
Jarle Greipsland in PR bin/7700.
1999-06-05 09:50:39 +00:00
christos
0b8b373b79
Limit wait time, so that people cannot use this as a flooding tool.
...
From bugtraq, but fixed differently than suggested.
1999-02-17 07:17:28 +00:00
cjs
b3523bee1d
Oops. We don't need limits.h in this program.
1999-02-16 23:27:43 +00:00
cjs
b8bcd9b643
If not root, make sure source address matches a local interface.
1999-02-16 23:18:40 +00:00
cjs
8164a79fad
Check select() return value, and abort the program if an error is
...
returned. Otherwise after sending a packet, select() may return
immediately (if there's an error of some sort) and traceroute
solders on, sending more packets with no delay in between. This is
effectively a small flood attack.
1999-02-16 20:47:24 +00:00
tron
8c2d809b71
Use a little bit of magic suggested by Ken Hornstein to find an
...
appropriate source address for the UDP packets. Fixes PR bin/4427
by Luke Mewburn.
1998-12-09 22:53:29 +00:00
ross
b1934d6034
{} fixes from Erik Bertelsen <erik@erik-be.uni-c.dk> (PR 6047) to shut up egcs.
1998-08-27 20:31:00 +00:00