2012-09-12 23:44:00 +00:00
|
|
|
#!/usr/bin/env ruby
|
2018-03-20 11:33:34 +00:00
|
|
|
|
|
|
|
##
|
|
|
|
# This module requires Metasploit: https://metasploit.com/download
|
|
|
|
# Current source: https://github.com/rapid7/metasploit-framework
|
|
|
|
##
|
|
|
|
|
2012-09-12 23:44:00 +00:00
|
|
|
#
|
|
|
|
# This script lists each exploit module by its compatible payloads
|
|
|
|
#
|
|
|
|
|
|
|
|
msfbase = __FILE__
|
|
|
|
while File.symlink?(msfbase)
|
2013-09-30 18:47:53 +00:00
|
|
|
msfbase = File.expand_path(File.readlink(msfbase), File.dirname(msfbase))
|
2012-09-12 23:44:00 +00:00
|
|
|
end
|
|
|
|
|
2015-10-06 15:30:52 +00:00
|
|
|
$:.unshift(File.expand_path(File.join(File.dirname(msfbase), '..', '..', 'lib')))
|
2012-09-12 23:44:00 +00:00
|
|
|
require 'msfenv'
|
|
|
|
|
|
|
|
$:.unshift(ENV['MSF_LOCAL_LIB']) if ENV['MSF_LOCAL_LIB']
|
|
|
|
|
|
|
|
require 'rex'
|
|
|
|
require 'msf/ui'
|
|
|
|
require 'msf/base'
|
|
|
|
|
|
|
|
# Initialize the simplified framework instance.
|
|
|
|
$framework = Msf::Simple::Framework.create('DisableDatabase' => true)
|
|
|
|
|
|
|
|
$framework.exploits.each_module { |name, mod|
|
2013-09-30 18:47:53 +00:00
|
|
|
x = mod.new
|
2012-09-12 23:44:00 +00:00
|
|
|
|
2013-09-30 18:47:53 +00:00
|
|
|
x.compatible_payloads.map{|n, m|
|
|
|
|
puts "#{x.refname.ljust 40} - #{n}"
|
|
|
|
}
|
2012-09-12 23:44:00 +00:00
|
|
|
}
|