summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJamie Nguyen <j@jamielinux.com>2018-07-11 13:02:54 +0100
committerJamie Nguyen <j@jamielinux.com>2018-07-11 13:02:54 +0100
commitbb597f2e95843eae0ea6bba1a1fdd9e0020a0add (patch)
tree0f357c2b327d6f0c4b8b27eedb82a7e353fc1f81 /lib
parentc42a0bef7d7194989cdacc317409fa4ac0b802a0 (diff)
Kill fallback SSL certificate check after 10 seconds
Diffstat (limited to 'lib')
-rw-r--r--lib/custodian/protocoltest/ssl.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/custodian/protocoltest/ssl.rb b/lib/custodian/protocoltest/ssl.rb
index 82754c6..0d52fcc 100644
--- a/lib/custodian/protocoltest/ssl.rb
+++ b/lib/custodian/protocoltest/ssl.rb
@@ -166,7 +166,7 @@ class SSLCheck
in_cert = false
# Run the command.
- out = `echo "" | openssl s_client -servername #{uri.host} -connect #{uri.host}:#{uri.port} 2>/dev/null`
+ out = `echo "" | timeout --kill-after=10s 10s openssl s_client -servername #{uri.host} -connect #{uri.host}:#{uri.port} 2>/dev/null`
# For each line of the output
out.split( /[\r\n]/ ).each do |line|