* allow a request to pass a timeout (and by allowing passing a timeout, the ability to not parse the response)

git-svn-id: file:///home/svn/incoming/trunk@3511 4d416f70-5f16-0410-b530-b9f4589650da
unstable
bmc 2006-02-06 20:22:47 +00:00
parent d14646e084
commit 32dfdc114c
1 changed files with 3 additions and 3 deletions

View File

@ -117,8 +117,8 @@ module Exploit::Remote::HttpClient
#
# Connects to the server, creates a request, sends the request, reads the response
#
def request(opts={})
c = connect
def request(opts={}, timeout = -1)
c = connect(opts)
if (datastore['HTTP::junk_pipeline'].to_i > 0)
c.junk_pipeline = datastore['HTTP::junk_pipeline'].to_i
@ -156,7 +156,7 @@ module Exploit::Remote::HttpClient
request.junk_self_referring_directories = 1
end
c.send_request(request)
c.send_request(request, timeout)
end
##