Avoid messages inside check

bug/bundler_fix
jvazquez-r7 2014-06-04 12:43:39 -05:00
parent 3869fcb438
commit 7a5b5d31f9
1 changed files with 4 additions and 10 deletions

View File

@ -129,22 +129,16 @@ class Metasploit3 < Msf::Exploit::Remote
def check
connect
vprint_status("#{peer} - Checking for Java Debugging Wire Protocol")
res = handshake
disconnect
unless res
vprint_error("Unable to determine due to a connection timeout")
if res.nil?
return Exploit::CheckCode::Unknown
elsif res == HANDSHAKE
return Exploit::CheckCode::Appears
end
return Exploit::CheckCode::Appears if res == HANDSHAKE
return Exploit::CheckCode::Safe
Exploit::CheckCode::Safe
end