summaryrefslogtreecommitdiff
path: root/lib/net/ssh/proxy
diff options
context:
space:
mode:
Diffstat (limited to 'lib/net/ssh/proxy')
-rw-r--r--lib/net/ssh/proxy/http.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/net/ssh/proxy/http.rb b/lib/net/ssh/proxy/http.rb
index 92c75a7..1cfaa62 100644
--- a/lib/net/ssh/proxy/http.rb
+++ b/lib/net/ssh/proxy/http.rb
@@ -51,7 +51,8 @@ module Net
# proxy that was requested when the socket factory was instantiated.
def open(host, port, connection_options)
socket = establish_connection(connection_options[:timeout])
- socket.write "CONNECT #{host}:#{port} HTTP/1.0\r\n"
+ socket.write "CONNECT #{host}:#{port} HTTP/1.1\r\n"
+ socket.write "Host: #{host}:#{port}\r\n"
if options[:user]
credentials = ["#{options[:user]}:#{options[:password]}"].pack("m*").gsub(/\s/, "")