Module: Msf::Exploit::Remote::BrowserAutopwn::AutopwnClassMethods

Defined in:
lib/msf/core/exploit/remote/browser_autopwn.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.extended(base) ⇒ Object



20
21
22
23
24
25
26
# File 'lib/msf/core/exploit/remote/browser_autopwn.rb', line 20

def self.extended(base)
  if base.const_defined? "Rank"
    @@autopwn_rank = base.const_get("Rank")
  else
    @@autopwn_rank = RankingName.invert['manual']
  end
end

Instance Method Details

#autopwn_info(opts = {}) ⇒ Object



32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/msf/core/exploit/remote/browser_autopwn.rb', line 32

def autopwn_info(opts={})
  # prefix_html and postfix_html are only used for noscript exploits
  # vuln_test is only used for javascript exploits
  @autopwn_opts = {}
  @autopwn_opts[:ua_name]      = opts[:ua_name] || nil
  @autopwn_opts[:ua_minver]    = opts[:ua_minver]  || opts[:ua_minversion] || nil
  @autopwn_opts[:ua_maxver]    = opts[:ua_maxver]  || opts[:ua_maxversion] || nil
  @autopwn_opts[:ua_ver]       = opts[:ua_ver]  || opts[:ua_version] || nil
  @autopwn_opts[:classid]      = opts[:classid] || opts[:clsid] || nil
  @autopwn_opts[:method]       = opts[:method]  || opts[:method] || nil
  @autopwn_opts[:javascript]   = (opts[:javascript].nil?) ? true : opts[:javascript]
  @autopwn_opts[:os_name]      = opts[:os_name] || nil
  @autopwn_opts[:os_ver]       = opts[:os_ver]  || opts[:os_version] || nil
  @autopwn_opts[:postfix_html] = opts[:postfix_html] || nil
  @autopwn_opts[:prefix_html]  = opts[:prefix_html]  || nil
  @autopwn_opts[:vuln_test]    = opts[:vuln_test] || opts[:vulntest] || ""

  @autopwn_opts[:rank]         = opts[:rank] || @@autopwn_rank
end

#autopwn_optsObject



28
29
30
# File 'lib/msf/core/exploit/remote/browser_autopwn.rb', line 28

def autopwn_opts
  @autopwn_opts.dup
end