summaryrefslogtreecommitdiffstats
path: root/sbin/ping/ping.c
AgeCommit message (Expand)AuthorFilesLines
2020-02-11Simplify and unify wording for the -I sourceaddr option in various places.deraadt1-2/+2
2020-01-04ping(8): improve "-i wait" parsing and error-checking codecheloha1-18/+22
2019-08-28At startup, unveil entire filesystem to read-only. If after privdrop, somederaadt1-1/+7
2019-07-20ping(8): don't round inter-packet delay up to HZcheloha1-6/+1
2019-06-28When system calls indicate an error they return -1, not some arbitraryderaadt1-25/+25
2019-03-19delay dropping privs a bit when root so that setrtable works.tedu1-3/+8
2018-11-13Fix previous, which broke ping -T.dhill1-2/+2
2018-11-11make all the setsockopt calls consistent.dlg1-35/+37
2018-11-10let -D work on ping6 too.dlg1-3/+10
2018-11-10add support for setting the traffic class on ipv6 packets.dlg1-4/+13
2018-10-14Fix ID commentskn1-4/+4
2018-10-14Remove unneeded sockaddr size checkskn1-7/+1
2018-07-21There is no need to initialise global and static local variables to zero,claudio1-8/+8
2018-07-18replace manual zero initialization of various fields with memset;florian1-7/+3
2018-07-18When running flood ping with count packets (-c) set an alarm afterflorian1-3/+20
2018-04-11Two fixes in ping:zhuk1-4/+4
2017-11-08Add a type cast to force signed comparison. This fixes a loopvisa1-2/+2
2017-07-08Consistently use if ((option & F_FOO) && (option & F_BAR)) instead offlorian1-4/+4
2017-07-08Consistently use if (option & F_FOO); from Klemens Nanni, thanks!florian1-6/+6
2017-07-05remove useless (void)printf casts, diff from Klemens Nanni, massagedflorian1-117/+117
2017-07-04calculate multiples of 4 smarter; from Klemens Nanniflorian1-2/+2
2017-07-04replace perror(3) with err(3); from Klemens Nanniflorian1-5/+3
2017-02-22Unbreak "ping6 -L"renato1-4/+9
2016-10-20Only drop to _ping user if invoked as root. If invoked as anflorian1-2/+2
2016-09-28Always do the setgroups, setresgid and setresuid even if if theflorian1-11/+17
2016-09-26Drop privileges to newly added _ping user/group.florian1-12/+17
2016-09-20whitespacederaadt1-3/+3
2016-09-19Only allow standard dot notation for IPv4 addresses.florian1-12/+2
2016-09-18unbreak IPv6 source selectionflorian1-2/+2
2016-09-18simplify startup, since we know earlier which type of socket we needderaadt1-26/+12
2016-09-18whitespacederaadt1-19/+19
2016-09-18If running in verbose mode and no source address has been specifiedflorian1-2/+2
2016-09-18Do not print 'ping6' in reporting output, just 'ping'.florian1-15/+4
2016-09-17backwards if(v6flag); pointed out by naddyflorian1-3/+3
2016-09-17The final merge ping6 into ping.florian1-127/+801
2016-09-17Use ECHOTMLEN define; no functional change.florian1-2/+2
2016-09-17iov_base is already set in this case; reduce diff to ping6(8).florian1-3/+2
2016-09-17MAXPAYLOAD is different between ping and ping6.florian1-3/+5
2016-09-17Just use AF_INET like everywhere else.florian1-2/+2
2016-09-17malloc sets errno; use err not errxflorian1-2/+2
2016-09-17whitespaceflorian1-2/+2
2016-09-17Make getting source address more AF independent.florian1-7/+6
2016-09-17If -I was not given hoist getting source address up.florian1-39/+37
2016-09-17Make source address selection more AF independent.florian1-16/+15
2016-09-17Introduce AF independent from.florian1-4/+4
2016-09-17Use AF independent dst where possible.florian1-6/+7
2016-09-17Blindly s/dst/dst4/ or s/dst/dst6/, AF independent dst will beflorian1-16/+16
2016-09-17We will need the variable name "from" soon, so free it up by renamingflorian1-10/+11
2016-09-17Reduce diff in pinger().florian1-2/+2
2016-09-17styleflorian1-4/+3