Class: Metasploit::Framework::ParsedOptions::Console

Inherits:
Base
  • Object
show all
Defined in:
lib/metasploit/framework/parsed_options/console.rb

Overview

Parsed options for Command::Console

Constant Summary

Constants inherited from Base

Base::DEFAULT_ENVIRONMENT

Instance Attribute Summary

Attributes inherited from Base

#positional

Instance Method Summary collapse

Methods inherited from Base

#configure, #environment!, #initialize

Constructor Details

This class inherits a constructor from Metasploit::Framework::ParsedOptions::Base

Instance Method Details

#optionsActiveSupport::OrderedOptions

Options parsed from msfconsole command-line.

Returns:

  • (ActiveSupport::OrderedOptions)

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# File 'lib/metasploit/framework/parsed_options/console.rb', line 6

def options
  unless @options
    super.tap { |options|
      options.console = ActiveSupport::OrderedOptions.new

      options.console.commands = []
      options.console.confirm_exit = false
      options.console.histfile = nil
      options.console.local_output = nil
      options.console.plugins = []
      options.console.quiet = false
      options.console.real_readline = false
      options.console.resources = []
      options.console.subcommand = :run
    }
  end

  @options
end