Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
|
|
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
my be readded later with proper comments
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
needed if multiple modes are used at once
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
|
|
We can perfectly do icmp without root by using capabalities. So,
instead of doing unsufficient checks beforehand, we just try and fail if
it doesn't work.
Signed-off-by: Danijel Tasov <m@rbfh.de>
|
|
|
|
|
|
|
|
|
|
* lib/utils_base.c
* plugins/check_curl.c
* plugins-root/check_dhcp.c
Removed a line which theoretically can not do anything, but there was
comment which indicated something else. Still trying this though.
|
|
|
|
|
|
This fixes a compiler warning which complains about an uninitialized
value for a variable which is then returned.
This had no real world impact, since the program would crash in the
branch where result is not set.
The variable is initialized to "-1" which would be the error for
inet_pton.
|
|
This fixes a compiler warning with no real world impact.
The compiler complains about a missing return, which is correct, but
in that scenario the program would crash anyways, so this has no impact.
|
|
|
|
Fix parsing of the long options --help and --version. The special
handling must be done before calling getopt().
This fixes erroneous output like:
./check_icmp --version
./check_icmp: invalid option -- '-'
./check_icmp: invalid option -- 'e'
./check_icmp: invalid option -- 'r'
./check_icmp: invalid option -- '-'
./check_icmp: invalid option -- 'e'
./check_icmp: invalid option -- 'r'
Signed-off-by: Aksel Sjögren <asjogren@itrsgroup.com>
|
|
|
|
|
|
|
|
address family and not sockaddr_storage (#1771)
Co-authored-by: Erik Sejr <eriks@ssimicro.com>
Co-authored-by: Lorenz <12514511+RincewindsHat@users.noreply.github.com>
|
|
* Fix different overflows
* Less includes
* Add testcases
* Remove unused variable
* Remove unused and commented includes
|
|
- add a test to check '-s'
|
|
|
|
|
|
Add missing "warn" threshold field in "pkt" perfdata output.
Perfdata should be interpreted as;
'label'=value[UOM];[warn];[crit];[min];[max]
With one field missing, the hardcoded min value '0' ended up in the
"crit" field, making applications interpreting the perfdata thining that
critical threshold is always exceeded.
Signed-off-by: Aksel Sjögren <asjogren@itrsgroup.com>
|
|
* try to use "/usr/sbin/ip" before "ifconfig" since the latter is
obsolete on Linux to figure out interface to listen for DHCP messages.
But keeping ifconfig method just in case.
Without this, tests fail on boxes without ifconfig AND the correct
interface named ethX.
* amend possible failure responses, as check_dhcp might get a DHCPOFFER,
but from an unexpected address - which happens if the box running
tests are on a network with a DHCP server.
|
|
Fixes "No rule to make target 'test-debug'" when running "make
test-debug" in root dir.
|
|
There is a small typo in plugins-root/check_icmp.c.
Should read `conspicuously` rather than `conspicuosly`.
|
|
Otherwise, it writes sizeof(size_t) bytes to &oldlen, smashing the stack.
|