about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorCase Duckworth2020-05-23 19:47:23 -0500
committerCase Duckworth2020-05-23 19:47:23 -0500
commit677b0b26222f0fa3a284f57caa3e0953d9b73319 (patch)
treefbd21934621059a0080027461d227d832718a460
parentAdd URL normalizing functions for use later (diff)
downloadbollux-677b0b26222f0fa3a284f57caa3e0953d9b73319.tar.gz
bollux-677b0b26222f0fa3a284f57caa3e0953d9b73319.zip
Add SNI support
-rwxr-xr-xbollux2
1 files changed, 2 insertions, 0 deletions
diff --git a/bollux b/bollux index 50b4a81..10b43d0 100755 --- a/bollux +++ b/bollux
@@ -199,6 +199,8 @@ request() { # request [-s SERVER] URL
199 log 5 "addr: $addr" 199 log 5 "addr: $addr"
200 200
201 sslcmd=(openssl s_client -crlf -ign_eof -quiet -connect "$serv") 201 sslcmd=(openssl s_client -crlf -ign_eof -quiet -connect "$serv")
202 # use SNI
203 sslcmd+=(-servername "${serv%:*}")
202 log "${sslcmd[@]}" 204 log "${sslcmd[@]}"
203 "${sslcmd[@]}" <<<"$addr" 2>/dev/null 205 "${sslcmd[@]}" <<<"$addr" 2>/dev/null
204} 206}