From a52c6a0b6c84ec4bdbc398ef2bff6af8850f6575 Mon Sep 17 00:00:00 2001 From: Napsty Date: Fri, 5 Jun 2020 14:48:39 +0200 Subject: [PATCH] Add parameter (-S) for custom SSL/TLS protocol version --- check_esxi_hardware.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/check_esxi_hardware.py b/check_esxi_hardware.py index cb8030b..07f9f01 100755 --- a/check_esxi_hardware.py +++ b/check_esxi_hardware.py @@ -742,6 +742,9 @@ if vendor=='auto': sys.exit (ExitUnknown) else: verboseoutput("Unknown CIM Error: %s" % args) + except pywbem._exceptions.ConnectionError as args: + print("UNKNOWN: {}".format(args)) + sys.exit (ExitUnknown) except pywbem.cim_http.AuthError as arg: verboseoutput("Global exit set to UNKNOWN") GlobalStatus = ExitUnknown @@ -773,6 +776,9 @@ for classe in ClassesToCheck : sys.exit (ExitUnknown) else: verboseoutput("Unknown CIM Error: %s" % args) + except pywbem._exceptions.ConnectionError as args: + print("UNKNOWN: {}".format(args)) + sys.exit (ExitUnknown) except pywbem.cim_http.AuthError as arg: verboseoutput("Global exit set to UNKNOWN") GlobalStatus = ExitUnknown