Module: Msf::Simple::Framework::PluginManager

Defined in:
lib/msf/base/simple/framework.rb

Overview

Extends the framework.plugins class instance to automatically check in the framework plugin's directory.

Instance Method Summary collapse

Instance Method Details

#load(path, opts = {}) ⇒ Object

Loads the supplied plugin by checking to see if it exists in the framework default plugin path as necessary.



28
29
30
31
32
33
34
35
36
# File 'lib/msf/base/simple/framework.rb', line 28

def load(path, opts = {})
  def_path = Msf::Config.plugin_directory + File::SEPARATOR + path

  if (File.exist?(def_path) or File.exist?(def_path + ".rb"))
    super(def_path, opts)
  else
    super
  end
end