#
b2b634ff |
| 21-Aug-2024 |
florian <florian@openbsd.org> |
Get rid of inet_aton
OK deraadt
|
#
82b846b2 |
| 24-Mar-2022 |
deraadt <deraadt@openbsd.org> |
whitespace niggle noticed during review
|
#
21b3e878 |
| 03-Sep-2021 |
florian <florian@openbsd.org> |
Make traceroute(8) faster by sending probes and doing DNS async.
Traditional traceroute would send one probe and then wait for up to 5 seconds for a reply and then send the next probe. On a lossy li
Make traceroute(8) faster by sending probes and doing DNS async.
Traditional traceroute would send one probe and then wait for up to 5 seconds for a reply and then send the next probe. On a lossy link that eventually ends in a black hole this would take about 15 minutes and people would hit control-c in anger.
This rewrites the traceroute engine to use libevent and asr's async DNS interface. Probes are now send every 30ms or as soon as we get an answer back. With that we got the 15 minute worse case down to about 10 seconds.
A minor adjustment that is possible with this is to delay printing a line until we get to a line with answers. This has two effects:
1) If there are intermediate hops that don't answer, output pauses for a bit so we keep the visual cue of "something might be wrong here". 2) If there is a black hole at the end, we don't print out many "* * *" lines and thus scrolling the interesting bits out of the terminal. We collapse those lines and just print 64 * * * at the end.
Unfortunately the -c option to send udp probes to a fixed port had to go for now. But we should be able to add it back.
"Once you have seen the new one you can't go back to the old one" & enthusiastic OK deraadt@ OK sthen@ "I am very distressed that florian went to bed without committing it" beck@
show more ...
|
#
0e1de0b3 |
| 31-Aug-2021 |
florian <florian@openbsd.org> |
Make includes follow style(9).
|
#
227bbaa6 |
| 28-Aug-2021 |
sthen <sthen@openbsd.org> |
whitespace nit
|
#
19f57270 |
| 28-Aug-2021 |
sthen <sthen@openbsd.org> |
Allow traceroute -w values down to 1 second, from John Carmack Change the default -w from 5 to 3 seconds, reducing the time it waits for a response. John proposed using 1 second for this, but several
Allow traceroute -w values down to 1 second, from John Carmack Change the default -w from 5 to 3 seconds, reducing the time it waits for a response. John proposed using 1 second for this, but several of us are familiar with networks where that would be likely to remove hops, 3 seems reasonable and still saves 6 seconds on a non-responding hop (there's always mtr if you need faster output). Feedback from various, ok phessler@ kn@ florian@
show more ...
|
#
bc5a8259 |
| 12-Jul-2021 |
beck <beck@openbsd.org> |
Change the error reporting pattern throughout the tree when unveil fails to report the path that the failure occured on. Suggested by deraadt@ after some tech discussion.
Work done and verified by A
Change the error reporting pattern throughout the tree when unveil fails to report the path that the failure occured on. Suggested by deraadt@ after some tech discussion.
Work done and verified by Ashton Fagg <ashton@fagg.id.au>
ok deraadt@ semarie@ claudio@
show more ...
|
#
70813041 |
| 11-Feb-2020 |
deraadt <deraadt@openbsd.org> |
Simplify and unify wording for the -I sourceaddr option in various places. This is somewhat related to the "-b bind_addr" option some programs have, which should get some cleanup also... input floria
Simplify and unify wording for the -I sourceaddr option in various places. This is somewhat related to the "-b bind_addr" option some programs have, which should get some cleanup also... input florian claudio jmc
show more ...
|
#
115bfdf8 |
| 28-Aug-2019 |
deraadt <deraadt@openbsd.org> |
At startup, unveil entire filesystem to read-only. If after privdrop, some implausible bug existed in the socket setup (mostly dns-related and setsockopt) it would be largely neutered. of course, a
At startup, unveil entire filesystem to read-only. If after privdrop, some implausible bug existed in the socket setup (mostly dns-related and setsockopt) it would be largely neutered. of course, a very restrictive pledge is installed soon after that... ok mestre brynet florian
show more ...
|
#
df69c215 |
| 28-Jun-2019 |
deraadt <deraadt@openbsd.org> |
When system calls indicate an error they return -1, not some arbitrary value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if
When system calls indicate an error they return -1, not some arbitrary value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
show more ...
|
#
c255d9b6 |
| 19-Mar-2019 |
tedu <tedu@openbsd.org> |
delay dropping privs a bit when root so that setrtable works. traceroute bits from benno. ok benno claudio
|
#
aacddbd0 |
| 12-Nov-2018 |
dlg <dlg@openbsd.org> |
get rid of useless casts on setsockopt calls
suggested by kn@ after similar changes to ping
|
#
73ce99fb |
| 10-Nov-2018 |
dlg <dlg@openbsd.org> |
add support for setting the traffic class on ipv6 packets.
it reuses the toskeyword handling that ipv4 uses for setting the tos field, which is equiavlent to traffic class.
ok florian@ denis@
|
#
8a24d67a |
| 20-Oct-2018 |
kn <kn@openbsd.org> |
Sync root check from ping
Sync ping.c r1.217 (20.10.2016) to only drop uid/gid if invoked as root.
OK sthen
|
#
7cda49b3 |
| 15-Oct-2018 |
florian <florian@openbsd.org> |
No need to check ai_addrlen when we already checked ai_family, we are copying into the right sized struct. We can also trust the resolver to give us IPv6 if we ask it to. OK kn, deraadt
|
#
95bc1d9b |
| 28-May-2017 |
benno <benno@openbsd.org> |
style(9) some variable declarations ok florian@
|
#
45f12a4c |
| 28-May-2017 |
benno <benno@openbsd.org> |
check_tos() gets a parameter so i can remove another global var. ok florian@
|
#
8f55caaa |
| 28-May-2017 |
benno <benno@openbsd.org> |
introduce struct tr_conf to keep all of the configuration. Functions needing access to any of those vars get it passed as a parameter. result: even less global vars. ok florian@
|
#
f68d7b96 |
| 28-May-2017 |
benno <benno@openbsd.org> |
move as many globals as possible into the main function - thats the only place where they are used. Only exception: v6flags - make it an argument to usage() ok florian@
|
#
0bb70a9e |
| 24-Jan-2017 |
florian <florian@openbsd.org> |
Tell traceroute6 to choose source address based on correct routing table. From dhill, tweeks by me. OK benno
|
#
fd4cc5ed |
| 13-Jan-2017 |
florian <florian@openbsd.org> |
traceroute never sees a timeout when poll(2) returns when it receives a packet not intended for us. E.g. a ping(8) is running in parallel. In this case we need to account for the time we already wait
traceroute never sees a timeout when poll(2) returns when it receives a packet not intended for us. E.g. a ping(8) is running in parallel. In this case we need to account for the time we already waited.
Pointed out by Gabriel Nieto <gabnietof AT gmail>, thanks!
Looks good to and input millert@
show more ...
|
#
8db0c4f0 |
| 28-Sep-2016 |
florian <florian@openbsd.org> |
Always do the setgroups, setresgid and setresuid even if if the unprivileged user is not present instead of erroring out. This lets ping and traceroute work in restricted enviornments like the bgplg
Always do the setgroups, setresgid and setresuid even if if the unprivileged user is not present instead of erroring out. This lets ping and traceroute work in restricted enviornments like the bgplg chroot. Problem reported by sthen@ input & prodding deraadt@
show more ...
|
#
0c227b93 |
| 27-Sep-2016 |
florian <florian@openbsd.org> |
Drop privileges to newly added _traceroute user/group. It does not buy us much when called as a unpriv user. But if run as root we can now lose privileges. Input deraadt@ OK benno@, sthen@
|
#
f0cfb74e |
| 19-Sep-2016 |
florian <florian@openbsd.org> |
Only allow standard dot notation for IPv4 addresses as target. We can get rid of inet_aton(3) and use the AF independent getaddrinfo(3). OK natano@, krw@, millert@, claudio@
|
#
baf808a4 |
| 03-Sep-2016 |
benno <benno@openbsd.org> |
rearrange code: traceroute.c now only contains main() and usage(), worker.c contains all other functions, and i tracked down which global variables are used in which file and marked them accordingly
rearrange code: traceroute.c now only contains main() and usage(), worker.c contains all other functions, and i tracked down which global variables are used in which file and marked them accordingly with static (or not). No functional change, just the basis of further work.
ok florian@, deraadt@
show more ...
|