Land #3700, @ringt fix for oracle_login
* Avoid retrying logins when connection cannot be stablishedbug/bundler_fix
commit
bedbffa377
|
@ -44,27 +44,28 @@ class Metasploit3 < Msf::Auxiliary
|
|||
print_status("Starting brute force on #{datastore['RHOST']}:#{datastore['RPORT']}...")
|
||||
|
||||
fd = CSV.foreach(list) do |brute|
|
||||
datastore['DBUSER'] = brute[2].downcase
|
||||
datastore['DBPASS'] = brute[3].downcase
|
||||
|
||||
datastore['DBUSER'] = brute[2].downcase
|
||||
datastore['DBPASS'] = brute[3].downcase
|
||||
|
||||
begin
|
||||
connect
|
||||
disconnect
|
||||
rescue ::OCIError => e
|
||||
begin
|
||||
connect
|
||||
disconnect
|
||||
rescue ::OCIError => e
|
||||
if e.to_s =~ /^ORA-12170:\s/
|
||||
print_error("#{datastore['RHOST']}:#{datastore['RPORT']} Connection timed out")
|
||||
break
|
||||
end
|
||||
else
|
||||
if (not e)
|
||||
report_auth_info(
|
||||
report_auth_info(
|
||||
:host => "#{datastore['RHOST']}",
|
||||
:port => "#{datastore['RPORT']}",
|
||||
:sname => 'oracle',
|
||||
:user => "#{datastore['SID']}/#{datastore['DBUSER']}",
|
||||
:pass => "#{datastore['DBPASS']}",
|
||||
:active => true
|
||||
)
|
||||
print_status("Found user/pass of: #{datastore['DBUSER']}/#{datastore['DBPASS']} on #{datastore['RHOST']} with sid #{datastore['SID']}")
|
||||
end
|
||||
end
|
||||
)
|
||||
print_status("Found user/pass of: #{datastore['DBUSER']}/#{datastore['DBPASS']} on #{datastore['RHOST']} with sid #{datastore['SID']}")
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue