Skip to content

Commit 4bff68f

Browse files
author
HD Moore
committed
Use the specified UA, dont duplicate ports
1 parent 6e84151 commit 4bff68f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

modules/auxiliary/scanner/http/open_proxy.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@ def run_host(target_host)
6868
target_ports = target_ports.sort_by { rand }
6969
end
7070

71+
target_ports = target_ports.uniq
72+
7173
site = datastore['SITE']
7274
user_agent = datastore['UserAgent']
7375

@@ -97,7 +99,7 @@ def write_request(method,site,user_agent)
9799
request = method + " http://" + site + "/ HTTP/1.1" + "\r\n" +
98100
"Host: " + site + "\r\n" +
99101
"Connection: close" + "\r\n" +
100-
"User-Agent: user_agent" + "\r\n" +
102+
"User-Agent: #{user_agent}" + "\r\n" +
101103
"Accept-Encoding: *" + "\r\n" +
102104
"Accept-Charset: ISO-8859-1,UTF-8;q=0.7,*;q=0.7" + "\r\n" +
103105
"Cache-Control: no" + "\r\n" +

0 commit comments

Comments
 (0)