Consistency and API conformance changes to LES
parent
4a91dfdcf5
commit
d264802ce0
|
@ -305,12 +305,14 @@ module Msf::Post::Common
|
|||
# Special handle some cases that ARCH_TYPES won't recognize.
|
||||
# https://msdn.microsoft.com/en-us/library/aa384274.aspx
|
||||
case target_arch
|
||||
when /i386/, /i686/
|
||||
when /i[3456]86|wow64/i
|
||||
return ARCH_X86
|
||||
when /amd64/i, /ia64/i
|
||||
when /(amd|ia|x)64/i
|
||||
return ARCH_X86_64
|
||||
end
|
||||
|
||||
# Detect tricky variants of architecture types upfront
|
||||
|
||||
# Rely on ARCH_TYPES to tell us a framework-recognizable ARCH.
|
||||
# Notice we're sorting ARCH_TYPES first, so that the longest string
|
||||
# goes first. This step is used because sometimes let's say if the target
|
||||
|
|
|
@ -88,7 +88,9 @@ class Metasploit3 < Msf::Post
|
|||
|
||||
|
||||
def set_module_options(mod)
|
||||
mod.datastore.merge!(self.datastore)
|
||||
self.datastore.each_pair do |k,v|
|
||||
mod.datastore[k] = v
|
||||
end
|
||||
if !mod.datastore['SESSION'] && session.present?
|
||||
mod.datastore['SESSION'] = session.sid
|
||||
end
|
||||
|
@ -120,6 +122,7 @@ class Metasploit3 < Msf::Post
|
|||
end
|
||||
end
|
||||
|
||||
|
||||
def show_found_exploits
|
||||
if datastore['VERBOSE']
|
||||
print_status("The following #{@local_exploits.length} exploit checks are being tried:")
|
||||
|
@ -151,7 +154,9 @@ class Metasploit3 < Msf::Post
|
|||
# If the datastore option is true, a detailed description will show
|
||||
if datastore['SHOWDESCRIPTION']
|
||||
# Formatting for the description text
|
||||
print_line Rex::Text.wordwrap(Rex::Text.compress(m.description), 2, 70)
|
||||
Rex::Text.wordwrap(Rex::Text.compress(m.description), 2, 70).split(/\n/).each do |line|
|
||||
print_line line
|
||||
end
|
||||
end
|
||||
else
|
||||
vprint_status("#{m.fullname}: #{checkcode.second}")
|
||||
|
@ -163,12 +168,13 @@ class Metasploit3 < Msf::Post
|
|||
end
|
||||
end
|
||||
report_note(
|
||||
:host => rhost,
|
||||
:type => "les_results",
|
||||
:data => results.inspect
|
||||
)
|
||||
:host => rhost,
|
||||
:type => "local.suggested_exploits",
|
||||
:data => results
|
||||
)
|
||||
end
|
||||
|
||||
|
||||
def is_check_interesting?(checkcode)
|
||||
[
|
||||
Msf::Exploit::CheckCode::Vulnerable,
|
||||
|
|
Loading…
Reference in New Issue