Module: Msf::Session::Provider::MultiCommandExecution

Defined in:
lib/msf/core/session/provider/multi_command_execution.rb

Overview

Executes multiple commands and optionally allows for reading/writing I/O to the new processes.

Instance Method Summary collapse

Instance Method Details

#close_cmd(cmd = nil) ⇒ Object

Closes a command that was executed. If no command is supplied, the default command is used.


49
50
# File 'lib/msf/core/session/provider/multi_command_execution.rb', line 49

def close_cmd(cmd = nil)
end

#exec_cmd(command, arguments = nil, opts = nil) ⇒ Object

Executes a command with the supplied options, returning a context that should be supplied to future calls. Supported options:

- Hidden
  Launch the command hidden from view.

28
29
# File 'lib/msf/core/session/provider/multi_command_execution.rb', line 28

def exec_cmd(command, arguments = nil, opts = nil)
end

#init_cmd(command, arguments = nil, opts = nil) ⇒ Object

Initializes the single command instance that will be used implicitly if no command is supplied to any of the functions.


18
19
# File 'lib/msf/core/session/provider/multi_command_execution.rb', line 18

def init_cmd(command, arguments = nil, opts = nil)
end

#read_cmd(length = nil, cmd = nil) ⇒ Object

Reads output from a command. If no command is supplied, the default command is used.


35
36
# File 'lib/msf/core/session/provider/multi_command_execution.rb', line 35

def read_cmd(length = nil, cmd = nil)
end

#write_cmd(buf, cmd = nil) ⇒ Object

Writes input to a command. If no command is supplied, the default command is used.


42
43
# File 'lib/msf/core/session/provider/multi_command_execution.rb', line 42

def write_cmd(buf, cmd = nil)
end