summaryrefslogtreecommitdiffstats
path: root/plugins/sslutils.c
diff options
context:
space:
mode:
authorLorenz Kästle <12514511+RincewindsHat@users.noreply.github.com>2025-09-15 13:18:17 +0200
committerGitHub <noreply@github.com>2025-09-15 13:18:17 +0200
commit8ef825d85fb4d09c32ca44c545d6eb8d995ddea4 (patch)
tree5ab7b18797dfd5849dec7827c87ca3bb5fcb0993 /plugins/sslutils.c
parenta3cf9041af810770daf5d9b83f1906fa9bb0dd11 (diff)
parent204cf956f0b3db90d079321ee957b3860da7e33f (diff)
downloadmonitoring-plugins-8ef825d85fb4d09c32ca44c545d6eb8d995ddea4.tar.gz
Merge pull request #2149 from RincewindsHat/clang-format
Clang format
Diffstat (limited to 'plugins/sslutils.c')
-rw-r--r--plugins/sslutils.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/plugins/sslutils.c b/plugins/sslutils.c
index 3ce6afed..0e6d7525 100644
--- a/plugins/sslutils.c
+++ b/plugins/sslutils.c
@@ -437,16 +437,14 @@ mp_subcheck mp_net_ssl_check_certificate(X509 *certificate, int days_till_exp_wa
437 xasprintf(&sc_cert.output, _("Certificate '%s' expired on %s"), commonName, timestamp); 437 xasprintf(&sc_cert.output, _("Certificate '%s' expired on %s"), commonName, timestamp);
438 sc_cert = mp_set_subcheck_state(sc_cert, STATE_CRITICAL); 438 sc_cert = mp_set_subcheck_state(sc_cert, STATE_CRITICAL);
439 } else if (days_left == 0) { 439 } else if (days_left == 0) {
440 xasprintf(&sc_cert.output, _("Certificate '%s' just expired (%s)"), commonName, 440 xasprintf(&sc_cert.output, _("Certificate '%s' just expired (%s)"), commonName, timestamp);
441 timestamp);
442 if (days_left > days_till_exp_crit) { 441 if (days_left > days_till_exp_crit) {
443 sc_cert = mp_set_subcheck_state(sc_cert, STATE_WARNING); 442 sc_cert = mp_set_subcheck_state(sc_cert, STATE_WARNING);
444 } else { 443 } else {
445 sc_cert = mp_set_subcheck_state(sc_cert, STATE_CRITICAL); 444 sc_cert = mp_set_subcheck_state(sc_cert, STATE_CRITICAL);
446 } 445 }
447 } else { 446 } else {
448 xasprintf(&sc_cert.output, _("Certificate '%s' will expire on %s"), commonName, 447 xasprintf(&sc_cert.output, _("Certificate '%s' will expire on %s"), commonName, timestamp);
449 timestamp);
450 sc_cert = mp_set_subcheck_state(sc_cert, STATE_OK); 448 sc_cert = mp_set_subcheck_state(sc_cert, STATE_OK);
451 } 449 }
452 X509_free(certificate); 450 X509_free(certificate);