Merge branch 'upstream-master' into HEAD

bug/bundler_fix
James Lee 2014-05-15 13:53:16 -05:00
commit efd0db9c39
5 changed files with 7 additions and 9 deletions

View File

@ -97,6 +97,9 @@ class Core
# mode. # mode.
DefangedProhibitedDataStoreElements = [ "MsfModulePaths" ] DefangedProhibitedDataStoreElements = [ "MsfModulePaths" ]
# Constant for disclosure date formatting in search functions
DISCLOSURE_DATE_FORMAT = "%Y-%m-%d"
# Returns the list of commands supported by this command dispatcher # Returns the list of commands supported by this command dispatcher
def commands def commands
{ {
@ -1477,7 +1480,7 @@ class Core
next if not o next if not o
if not o.search_filter(match) if not o.search_filter(match)
tbl << [ o.fullname, o.disclosure_date.to_s, o.rank_to_s, o.name ] tbl << [ o.fullname, o.disclosure_date.nil? ? "" : o.disclosure_date.strftime(DISCLOSURE_DATE_FORMAT), o.rank_to_s, o.name ]
end end
end end
end end
@ -1492,7 +1495,7 @@ class Core
def search_modules_sql(search_string) def search_modules_sql(search_string)
tbl = generate_module_table("Matching Modules") tbl = generate_module_table("Matching Modules")
framework.db.search_modules(search_string).each do |o| framework.db.search_modules(search_string).each do |o|
tbl << [ o.fullname, o.disclosure_date.to_s, RankingName[o.rank].to_s, o.name ] tbl << [ o.fullname, o.disclosure_date.nil? ? "" : o.disclosure_date.strftime(DISCLOSURE_DATE_FORMAT), RankingName[o.rank].to_s, o.name ]
end end
print_line(tbl.to_s) print_line(tbl.to_s)
end end
@ -3270,7 +3273,7 @@ class Core
end end
end end
if (opts == nil or show == true) if (opts == nil or show == true)
tbl << [ refname, o.disclosure_date||"", o.rank_to_s, o.name ] tbl << [ refname, o.disclosure_date.nil? ? "" : o.disclosure_date.strftime(DISCLOSURE_DATE_FORMAT), o.rank_to_s, o.name ]
end end
end end
end end

View File

@ -6,7 +6,6 @@
require 'msf/core' require 'msf/core'
class Metasploit3 < Msf::Auxiliary class Metasploit3 < Msf::Auxiliary
Rank = ManualRanking
include Msf::Exploit::Remote::Tcp include Msf::Exploit::Remote::Tcp
include Msf::Auxiliary::Dos include Msf::Auxiliary::Dos

View File

@ -10,9 +10,6 @@ class Metasploit3 < Msf::Auxiliary
include Msf::Exploit::Capture include Msf::Exploit::Capture
include Msf::Auxiliary::Dos include Msf::Auxiliary::Dos
# The whole point is to cause a router crash.
Rank = ManualRanking
def initialize def initialize
super( super(
'Name' => 'Juniper JunOS Malformed TCP Option', 'Name' => 'Juniper JunOS Malformed TCP Option',

View File

@ -4,7 +4,6 @@
## ##
class Metasploit3 < Msf::Auxiliary class Metasploit3 < Msf::Auxiliary
Rank = ManualRanking
include Msf::Exploit::Remote::Udp include Msf::Exploit::Remote::Udp
#include Msf::Exploit::Remote::SMB #include Msf::Exploit::Remote::SMB

View File

@ -82,7 +82,7 @@ describe Msf::Ui::Console::CommandDispatcher::Core do
end end
it 'should have disclosure date in second column' do it 'should have disclosure date in second column' do
cell(printed_table, 0, 1).should include(module_detail.disclosure_date.to_s) cell(printed_table, 0, 1).should include(module_detail.disclosure_date.strftime("%Y-%m-%d"))
end end
it 'should have rank name in third column' do it 'should have rank name in third column' do