From 8ee62157d98e751b1e9bf777e7821ceb9374b5c4 Mon Sep 17 00:00:00 2001 From: Denny Fuchs Date: Tue, 1 Sep 2020 13:02:26 +0200 Subject: [PATCH] Add SSL_verify_mode to fix problem with disable verify hostname This param fixes the error with disable_sslverifyhostname, which does not work, until the [option](https://metacpan.org/pod/IO::Socket::SSL) was set. --- check_nginx_status.pl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/check_nginx_status.pl b/check_nginx_status.pl index 02b1c34..81e874d 100755 --- a/check_nginx_status.pl +++ b/check_nginx_status.pl @@ -215,7 +215,9 @@ sub check_options { ); if ( $o_disable_sslverifyhostname ) { - $ua->ssl_opts( 'verify_hostname' => 0 ); + $ua->ssl_opts( 'verify_hostname' => 0, + SSL_verify_mode => '0', + ); } # we need to enforce the HTTP request is made on the Nagios Host IP and