diff options
| author | Lorenz Kästle <12514511+RincewindsHat@users.noreply.github.com> | 2025-06-12 13:45:21 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-12 13:45:21 +0200 |
| commit | 916d3a52a0f01f05bbf42008fa5dddcee6ad7522 (patch) | |
| tree | e2b5a0c853b64074e8734dbe3b5de5b2c45fc8ed /plugins/check_fping.d/config.h | |
| parent | af88e3ced3c49169ed57fa4b4eaf6b4d8bb39ba7 (diff) | |
| parent | a669b2531d3b01aeb5b3e39c28bf2e6816fb14af (diff) | |
| download | monitoring-plugins-916d3a52a0f01f05bbf42008fa5dddcee6ad7522.tar.gz | |
Merge pull request #2129 from RincewindsHat/check_fping_5.3_options
Add fping 5.2 and 5.3 options to check_fping
Diffstat (limited to 'plugins/check_fping.d/config.h')
| -rw-r--r-- | plugins/check_fping.d/config.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/plugins/check_fping.d/config.h b/plugins/check_fping.d/config.h index a0697bf3..d95e9ded 100644 --- a/plugins/check_fping.d/config.h +++ b/plugins/check_fping.d/config.h | |||
| @@ -29,6 +29,21 @@ typedef struct { | |||
| 29 | bool cpl_p; | 29 | bool cpl_p; |
| 30 | int wpl; | 30 | int wpl; |
| 31 | bool wpl_p; | 31 | bool wpl_p; |
| 32 | |||
| 33 | // only available with fping version >= 5.2 | ||
| 34 | // for a given uint _fwmark_ fping sets _fwmark_ as a firewall mark | ||
| 35 | // in the packets | ||
| 36 | unsigned int fwmark; | ||
| 37 | bool fwmark_set; | ||
| 38 | |||
| 39 | |||
| 40 | // only available with fping version >= 5.3 | ||
| 41 | // Setting icmp_timestamp tells fping to use ICMP Timestamp (ICMP type 13) instead | ||
| 42 | // of ICMP Echo | ||
| 43 | bool icmp_timestamp; | ||
| 44 | |||
| 45 | // Setting check_source lets fping discard replies which are not from the target address | ||
| 46 | bool check_source; | ||
| 32 | } check_fping_config; | 47 | } check_fping_config; |
| 33 | 48 | ||
| 34 | check_fping_config check_fping_config_init() { | 49 | check_fping_config check_fping_config_init() { |
| @@ -53,6 +68,15 @@ check_fping_config check_fping_config_init() { | |||
| 53 | .cpl_p = false, | 68 | .cpl_p = false, |
| 54 | .wpl = 0, | 69 | .wpl = 0, |
| 55 | .wpl_p = false, | 70 | .wpl_p = false, |
| 71 | |||
| 72 | // only available with fping version >= 5.2 | ||
| 73 | .fwmark = 0, | ||
| 74 | .fwmark_set = false, // just to be deterministic | ||
| 75 | |||
| 76 | // only available with fping version >= 5.3 | ||
| 77 | .icmp_timestamp = false, | ||
| 78 | .check_source = false, | ||
| 79 | |||
| 56 | }; | 80 | }; |
| 57 | return tmp; | 81 | return tmp; |
| 58 | } | 82 | } |
