Add PATH option. Feature #5412
git-svn-id: file:///home/svn/framework3/trunk@14067 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
5ce859d3ad
commit
ab4f9d65c7
|
@ -31,13 +31,17 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
'License' => MSF_LICENSE
|
'License' => MSF_LICENSE
|
||||||
)
|
)
|
||||||
|
|
||||||
|
register_options(
|
||||||
|
[
|
||||||
|
OptString.new('PATH', [true, "Path to use", '/']),
|
||||||
|
], self.class)
|
||||||
end
|
end
|
||||||
|
|
||||||
def run_host(target_host)
|
def run_host(target_host)
|
||||||
|
|
||||||
begin
|
begin
|
||||||
res = send_request_raw({
|
res = send_request_raw({
|
||||||
'uri' => '/',
|
'uri' => datastore['PATH'],
|
||||||
'method' => 'OPTIONS'
|
'method' => 'OPTIONS'
|
||||||
}, 10)
|
}, 10)
|
||||||
|
|
||||||
|
|
|
@ -31,13 +31,17 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
'License' => MSF_LICENSE
|
'License' => MSF_LICENSE
|
||||||
)
|
)
|
||||||
|
|
||||||
|
register_options(
|
||||||
|
[
|
||||||
|
OptString.new('PATH', [true, "Path to use", '/']),
|
||||||
|
], self.class)
|
||||||
end
|
end
|
||||||
|
|
||||||
def run_host(target_host)
|
def run_host(target_host)
|
||||||
|
|
||||||
begin
|
begin
|
||||||
res = send_request_cgi({
|
res = send_request_cgi({
|
||||||
'uri' => '/',
|
'uri' => datastore['PATH'],
|
||||||
'method' => 'PROPFIND',
|
'method' => 'PROPFIND',
|
||||||
'data' => '',
|
'data' => '',
|
||||||
'ctype' => 'text/xml',
|
'ctype' => 'text/xml',
|
||||||
|
@ -54,7 +58,6 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
|
|
||||||
result = res.body.scan(urlregex).uniq
|
result = res.body.scan(urlregex).uniq
|
||||||
|
|
||||||
|
|
||||||
result.each do |u|
|
result.each do |u|
|
||||||
print_status("Found file or directory in WebDAV response (#{target_host}) #{u}")
|
print_status("Found file or directory in WebDAV response (#{target_host}) #{u}")
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue