some minor fixes
parent
8de2109f97
commit
4453dcdc8e
|
@ -84,8 +84,8 @@ class Metasploit::Framework::CredentialCollection
|
||||||
|
|
||||||
prepended_creds.each { |c| yield c }
|
prepended_creds.each { |c| yield c }
|
||||||
|
|
||||||
if username
|
if username.present?
|
||||||
if password
|
if password.present?
|
||||||
yield Metasploit::Framework::Credential.new(public: username, private: password, realm: realm)
|
yield Metasploit::Framework::Credential.new(public: username, private: password, realm: realm)
|
||||||
end
|
end
|
||||||
if user_as_pass
|
if user_as_pass
|
||||||
|
@ -103,7 +103,7 @@ class Metasploit::Framework::CredentialCollection
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if user_file
|
if user_file.present?
|
||||||
File.open(user_file, 'r:binary') do |user_fd|
|
File.open(user_file, 'r:binary') do |user_fd|
|
||||||
user_fd.each_line do |user_from_file|
|
user_fd.each_line do |user_from_file|
|
||||||
user_from_file.chomp!
|
user_from_file.chomp!
|
||||||
|
@ -127,7 +127,7 @@ class Metasploit::Framework::CredentialCollection
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if userpass_file
|
if userpass_file.present?
|
||||||
File.open(userpass_file, 'r:binary') do |userpass_fd|
|
File.open(userpass_file, 'r:binary') do |userpass_fd|
|
||||||
userpass_fd.each_line do |line|
|
userpass_fd.each_line do |line|
|
||||||
user, pass = line.split(" ", 2)
|
user, pass = line.split(" ", 2)
|
||||||
|
|
|
@ -6,6 +6,8 @@
|
||||||
|
|
||||||
require 'msf/core'
|
require 'msf/core'
|
||||||
require 'rex/proto/ntlm/message'
|
require 'rex/proto/ntlm/message'
|
||||||
|
require 'metasploit/framework/credential_collection'
|
||||||
|
require 'metasploit/framework/login_scanner/http'
|
||||||
|
|
||||||
|
|
||||||
class Metasploit3 < Msf::Auxiliary
|
class Metasploit3 < Msf::Auxiliary
|
||||||
|
|
Loading…
Reference in New Issue