Final round of documentation

This commit is contained in:
wchen-r7 2015-04-24 11:58:12 -05:00
parent 6ccc4af4d8
commit 46361c1a19
7 changed files with 147 additions and 140 deletions

View File

@ -40,7 +40,8 @@ class Client
end
# Logs in by calling the 'auth.login' API.
# Logs in by calling the 'auth.login' API. The authentication token will expire 5 minutes
# after the last request was made.
#
# @param [String] user Username.
# @param [String] pass Password.

View File

@ -11,7 +11,8 @@ begin
rescue ::LoadError
end
# Handles client authentication.
# Handles client authentication. The authentication token will expire 5 minutes after the
# last request was made.
#
# @param [String] user The username.
# @param [String] pass The password.
@ -79,7 +80,8 @@ end
end
# Returns a list of authentication tokens.
# Returns a list of authentication tokens including the temporary ones, permanent, or the ones
# stored in the backend.
#
# @return [Hash] A hash that contains a list of authentication tokens. It contains the following key:
# * 'tokens' [Array<string>] An array of tokens.
@ -128,10 +130,10 @@ end
end
# Generates a unique token, and automatically saved to the database.
# Generates a random 32-byte authentication token, and automatically saved to the database.
#
# @return [Hash] A hash indicating the action was successful, also the new token.
# It contains the following keys:
# It contains the following keys:
# * 'result' [String] The successful message: 'success'
# * 'token' [String] A new token.
# @example Here's how you would use this from the client:
@ -158,8 +160,10 @@ end
end
# Removes a token from the database.
# Removes a token from the database. Similar to what #rpc_logout does internally, except this
# can remove tokens stored in the database backend (Mdm).
#
# @see #rpc_logout
# @param [String] token The token to delete.
# @return [Hash] A hash indicating the action was successful. It contains the following key:
# * 'result' [String] The successful message: 'success'

View File

@ -15,7 +15,7 @@ class RPC_Console < RPC_Base
@console_driver = Msf::Ui::Web::Driver.new(:framework => framework)
end
# Creates a new framework console.
# Creates a new framework console instance.
#
# @param [Hash] opts See Msf::Ui::Web::Driver#create_console
# @return [Hash] Information about the new console. It contains the following keys:
@ -58,7 +58,7 @@ class RPC_Console < RPC_Base
end
# Deletes a framework console.
# Deletes a framework console instance.
#
# @param [Fixnum] cid Framework console ID.
# @return [Hash] A result indicating whether the action was successful or not.
@ -74,7 +74,7 @@ class RPC_Console < RPC_Base
end
# Returns the framework console output.
# Returns the framework console output in raw form.
#
# @param [Fixnum] cid Framework console ID.
# @return [Hash] There are two different hashes you might get:
@ -143,15 +143,12 @@ class RPC_Console < RPC_Base
end
# Kills a framework session.
# Kills a framework session that serves the same purpose as [CTRL]+[C] to abort an interactive session.
# You might also want to considering using the session API calls instead of this.
#
# @param [Fixnum] cid Framework console ID.
# @return [Hash] There are two different hashes you might get:
#
# If the console ID is invalid, you will get a hash like the following:
# * 'result' [String] A value that says 'failure'.
# If the console ID is valid, you will get the following that indicates the action was successful.
# * 'result' [String] A value that says 'success'.
# @return [Hash] A hash indicating whether the action was successful or not. It contains:
# * 'result' [String] A message that says 'success' if the console ID is valid (and successfully killed, otherwise 'failed')
# @example Here's how you would use this from the client:
# rpc.call('console.session_kill', 4)
def rpc_session_kill(cid)
@ -162,15 +159,11 @@ class RPC_Console < RPC_Base
end
# Detaches a framework session.
# Detaches a framework session that serves the same purpos as [CTRL]+[Z] to background an interactive session.
#
# @param [Fixnum] cid Framework console ID.
# @return [Hash] There are two different hashes you might get:
#
# If the console ID is invalid, you will get a hash like the following:
# * 'result' [String] A value that says 'failure'.
# If the console ID is valid, you will get the following that indicates the action was successful.
# * 'result' [String] A value that says 'success'.
# @return [Hash] A hash indicating whether the action was successful or not. It contains:
# * 'result' [String] A message that says 'success' if the console ID is valid (and successfully detached, otherwise 'failed')
# @example Here's how you would use this from the client:
# rpc.call('console.session_detach', 4)
def rpc_session_detach(cid)

View File

@ -98,7 +98,10 @@ class RPC_Core < RPC_Base
end
# Adds a new module path.
# Adds a new local file system path (local to the server) as a module path. The module must be
# accessible to the user running the Metasploit service, and contain a top-level directory for
# each module type such as: exploits, nop, encoder, payloads, auxiliary, post. Also note that
# this will not unload modules that were deleted from the file system that were previously loaded.
#
# @param [String] path The new path to load.
# @return [Hash] Module stats that contain the following keys:

View File

@ -222,14 +222,14 @@ public
# * 500 Invalid workspace.
# @return [Hash] Credentials with the following hash key:
# * 'creds' [Array<Hash>] An array of credentials. Each hash in the array will have the following:
# * 'user' [String] Username.
# * 'pass' [String] Password.
# * 'updated_at' [Fixnum] Last updated at.
# * 'type' [String] Password type.
# * 'host' [String] Host.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'sname' [String] Service name.
# * 'user' [String] Username.
# * 'pass' [String] Password.
# * 'updated_at' [Fixnum] Last updated at.
# * 'type' [String] Password type.
# * 'host' [String] Host.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'sname' [String] Service name.
# @example Here's how you would use this from the client:
# rpc.call('db.creds', {})
def rpc_creds(xopts)
@ -277,7 +277,6 @@ public
# * 500 ActiveRecord::ConnectionNotEstablished. Try: rpc.call('console.create').
# * 500 Database not loaded. Try: rpc.call('console.create')
# * 500 Invalid workspace.
# You probably want to run: rpc.call('console.create').
# @return [Hash] Host information that starts with the following hash key:
# * 'hosts' [Array<Hash>] An array of hosts. Each hash in the array will have the following:
# * 'created_at' [Fixnum] Creation date.
@ -451,10 +450,10 @@ public
# @raise [Msf::RPC::Exception] Database not loaded.
# @return [Hash] A hash with the following key:
# * 'workspaces' [Array<Hash>] In each hash of the array, you will get these keys:
# * 'id' [Fixnum] Workspace ID.
# * 'name' [String] Workspace name.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# * 'id' [Fixnum] Workspace ID.
# * 'name' [String] Workspace name.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# @example Here's how you would use this from the client:
# rpc.call('db.workspaces')
def rpc_workspaces
@ -496,10 +495,10 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash with the following key:
# * 'workspace' [Array<Hash>] In each hash of the array, you will get these keys:
# * 'name' [String] Workspace name.
# * 'id' [Fixnum] Workspace ID.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Workspace name.
# * 'id' [Fixnum] Workspace ID.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# @example Here's how you would use this from the client:
# rpc.call('db.get_workspace')
def rpc_get_workspace(wspace)
@ -606,18 +605,18 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'host' [Array<Hash>] Each hash in the array contains the following:
# * 'created_at' [Fixnum] Last created at.
# * 'address' [String] Address.
# * 'mac' [String] Mac address.
# * 'name' [String] Host name.
# * 'state' [String] Host state.
# * 'os_name' [String] OS name.
# * 'os_flavor' [String] OS flavor.
# * 'os_sp' [String] OS service pack.
# * 'os_lang' [String] OS language.
# * 'updated_at' [Fixnum] Last updated at.
# * 'purpose' [String] Purpose. Example: 'server'.
# * 'info' [String] Additional information.
# * 'created_at' [Fixnum] Last created at.
# * 'address' [String] Address.
# * 'mac' [String] Mac address.
# * 'name' [String] Host name.
# * 'state' [String] Host state.
# * 'os_name' [String] OS name.
# * 'os_flavor' [String] OS flavor.
# * 'os_sp' [String] OS service pack.
# * 'os_lang' [String] OS language.
# * 'updated_at' [Fixnum] Last updated at.
# * 'purpose' [String] Purpose. Example: 'server'.
# * 'info' [String] Additional information.
# @example Here's how you would use this from the client:
# rpc.call('db.get_host', {:host => ip})
def rpc_get_host(xopts)
@ -722,13 +721,13 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following key:
# * 'service' [Array<Hash>] Each hash in the array contains the following:
# * 'host' [String] Host address.
# * 'created_at' [Fixnum] Creation date.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'state' [String] Service state.
# * 'name' [String] Service name.
# * 'info' [String] Additional information.
# * 'host' [String] Host address.
# * 'created_at' [Fixnum] Creation date.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'state' [String] Service state.
# * 'name' [String] Service name.
# * 'info' [String] Additional information.
# @example Here's how you would use this from the client:
# rpc.call('db.get_service', {:workspace=>'default', :proto=>'tcp', :port=>443})
def rpc_get_service(xopts)
@ -790,15 +789,15 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'note' [Array<Hash>] Each hash in the array contains the following:
# * 'host' [String] Host.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# * 'ntype' [String] Note type.
# * 'data' [String] Note data.
# * 'critical' [String] A boolean indicating criticality.
# * 'seen' [String] A boolean indicating whether the note has been seen before.
# * 'host' [String] Host.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'created_at' [Fixnum] Last created at.
# * 'updated_at' [Fixnum] Last updated at.
# * 'ntype' [String] Note type.
# * 'data' [String] Note data.
# * 'critical' [String] A boolean indicating criticality.
# * 'seen' [String] A boolean indicating whether the note has been seen before.
# @example Here's how you would use this from the client:
# rpc.call('db.get_note', {:proto => 'tcp', :port => 80})
def rpc_get_note(xopts)
@ -866,12 +865,12 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the client connection:
# * 'client' [Array<Hash>] Each hash of the array contains the following:
# * 'host' [String] Host IP.
# * 'created_at' [Fixnum] Created date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'ua_string' [String] User-Agent string.
# * 'ua_name' [String] User-Agent name.
# * 'ua_ver' [String] User-Agent version.
# * 'host' [String] Host IP.
# * 'created_at' [Fixnum] Created date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'ua_string' [String] User-Agent string.
# * 'ua_name' [String] User-Agent name.
# * 'ua_ver' [String] User-Agent version.
# @example Here's how you would use this from the client:
# rpc.call('db.get_client', {:workspace=>'default', :ua_string=>user_agent, :host=>ip})
def rpc_get_client(xopts)
@ -977,11 +976,11 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'notes' [Array<Hash>] Each hash in the array contains the following:
# * 'time' [Fixnum] Creation date.
# * 'host' [String] Host address.
# * 'service' [String] Service name or port.
# * 'type' [String] Host type.
# * 'data' [String] Host data.
# * 'time' [Fixnum] Creation date.
# * 'host' [String] Host address.
# * 'service' [String] Service name or port.
# * 'type' [String] Host type.
# * 'data' [String] Host data.
# @example Here's how you would use this from the client:
# # This gives you all the notes.
# rpc.call('db.notes', {})
@ -1051,10 +1050,10 @@ public
# @return [Hash] A hash that contains the following:
# * 'result' [String] A message that says 'success'.
# * 'deleted' [Array<Hash>] Each hash in the array contains the following:
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'name' [String] Vulnerability name.
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'name' [String] Vulnerability name.
# @example Here's how you would use this from the client:
# rpc.call('db.del_vuln', {:host=>ip, :port=>445, :proto=>'tcp'})
def rpc_del_vuln(xopts)
@ -1144,10 +1143,10 @@ public
# @return [Hash] A hash that contains the following:
# * 'result' [String] A message that says 'success'.
# * 'deleted' [Array<Hash>] Each hash in the array contains the following:
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto'[String] Protocol.
# * 'ntype' [String] Note type.
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'ntype' [String] Note type.
# @example Here's how you would use this from the client:
# rpc.call('db.del_note', {:workspace=>'default', :host=>ip, :port=>443, :proto=>'tcp'})
def rpc_del_note(xopts)
@ -1235,10 +1234,10 @@ public
# @return [Hash] A hash that contains the following:
# * 'result' [String] A message that says 'success' or 'failed'.
# * 'deleted' [Array<Hash>] If result says success, then you will get this key.
# Each hash in the array contains the following:
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# Each hash in the array contains:
# * 'address' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# @example Here's how you would use this from the client:
# rpc.call('db.del_service', {:host=>ip})
def rpc_del_service(xopts)
@ -1310,8 +1309,8 @@ public
# * 500 Database not loaded. Try: rpc.call('console.create')
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# 'result' [String] A message that says 'success'.
# 'deleted' [Array] All the deleted hosts.
# * 'result' [String] A message that says 'success'.
# * 'deleted' [Array<String>] All the deleted hosts.
# @example Here's how you would use this from the client:
# rpc.call('db.del_host', {:host=>ip})
def rpc_del_host(xopts)
@ -1358,7 +1357,7 @@ public
# * 500 Database not loaded. Try: rpc.call('console.create')
# * 500 Invalid workspace.
# @return [Hash] A hash indicating whether the action was successful or not. It contains:
# 'result' [String] A message that says either 'success' or 'failed'.
# * 'result' [String] A message that says either 'success' or 'failed'.
# @example Here's how you would use this from the client:
# rpc.call('db.report_vuln', {:host=>ip, :name=>'file upload'})
def rpc_report_vuln(xopts)
@ -1385,13 +1384,13 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'events' [Array<Hash>] Each hash in the array contains the following:
# * 'host' [String] Host address.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Event name.
# * 'critical' [Boolean] Criticality.
# * 'username' [String] Username.
# * 'info' [String] Additional information.
# * 'host' [String] Host address.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Event name.
# * 'critical' [Boolean] Criticality.
# * 'username' [String] Username.
# * 'info' [String] Additional information.
# @example Here's how you would use this from the client:
# rpc.call('db.events', {})
def rpc_events(xopts)
@ -1489,15 +1488,15 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'loots' [Array<Hash>] Each hash in the array contains the following:
# * 'host' [String] Host address.
# * 'service' [String] Service name or port.
# * 'ltype' [String] Loot type.
# * 'ctype' [String] Content type.
# * 'data' [String] Looted data.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Name.
# * 'info' [String] Additional information.
# * 'host' [String] Host address.
# * 'service' [String] Service name or port.
# * 'ltype' [String] Loot type.
# * 'ctype' [String] Content type.
# * 'data' [String] Looted data.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Name.
# * 'info' [String] Additional information.
# @example Here's how you would use this from the client:
# rpc.call('db.loots', {})
def rpc_loots(xopts)
@ -1593,14 +1592,14 @@ public
# * 500 Invalid workspace.
# @return [Hash] A hash that contains the following:
# * 'vuln' [Array<Hash>] Each hash in the array contains the following:
# * 'host' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Vulnerability name.
# * 'info' [String] Additional information.
# * 'refs' [Array<String>] Reference names.
# * 'host' [String] Host address.
# * 'port' [Fixnum] Port.
# * 'proto' [String] Protocol.
# * 'created_at' [Fixnum] Creation date.
# * 'updated_at' [Fixnum] Last updated at.
# * 'name' [String] Vulnerability name.
# * 'info' [String] Additional information.
# * 'refs' [Array<String>] Reference names.
# @example Here's how you would use this from the client:
# rpc.call('db.get_vuln', {:proto=>'tcp'})
def rpc_get_vuln(xopts)
@ -1719,8 +1718,8 @@ public
# @return [Hash] A hash that contains the following:
# * 'result' [String] A message that says 'success'.
# * 'deleted' [Array<Hash>] Each hash in the array contains the following:
# * 'address' [String] Host address.
# * 'ua_string' [String] User-Agent string.
# * 'address' [String] Host address.
# * 'ua_string' [String] User-Agent string.
# @example Here's how you would use this from the client:
# rpc.call('db.del_client', {})
def rpc_del_client(xopts)
@ -1871,7 +1870,9 @@ public
# Disconnects the database.
#
# @return [Hash] A hash that indicates whether the action was successful or not. It contains:
# 'result' [String] A message that says either 'success' or 'failed'.
# * 'result' [String] A message that says either 'success' or 'failed'.
# @example Here's how you would use this from the client:
# rpc.call('db.disconnect')
def rpc_disconnect
if (self.framework.db)
self.framework.db.disconnect()

View File

@ -4,7 +4,7 @@ module Msf
module RPC
class RPC_Module < RPC_Base
# Returns a list of exploit names.
# Returns a list of exploit names. The 'exploit/' prefix will not be included.
#
# @return [Hash] A list of exploit names. It contains the following key:
# * 'modules' [Array<string>] Exploit names, for example: ['windows/wins/ms04_045_wins']
@ -15,7 +15,7 @@ class RPC_Module < RPC_Base
end
# Returns a list of auxiliary module names.
# Returns a list of auxiliary module names. The 'auxiliary/' prefix will not be included.
#
# @return [Hash] A list of auxiliary module names. It contains the following key:
# * 'modules' [Array<string>] Auxiliary module names, for example: ['vsploit/pii/web_pii']
@ -26,7 +26,7 @@ class RPC_Module < RPC_Base
end
# Returns a list of payload module names.
# Returns a list of payload module names. The 'payload/' prefix will not be included.
#
# @return [Hash] A list of payload module names. It contains the following key:
# * 'modules' [Array<string>] Payload module names, for example: ['windows/x64/shell_reverse_tcp']
@ -37,7 +37,7 @@ class RPC_Module < RPC_Base
end
# Returns a list of encoder module names.
# Returns a list of encoder module names. The 'encoder/' prefix will not be included.
#
# @return [Hash] A list of encoder module names. It contains the following key:
# * 'modules' [Array<string>] Encoder module names, for example: ['x86/unicode_upper']
@ -48,7 +48,7 @@ class RPC_Module < RPC_Base
end
# Returns a list of NOP module names.
# Returns a list of NOP module names. The 'nop/' prefix will not be included.
#
# @return [Hash] A list of NOP module names. It contains the following key:
# * 'modules' [Array<string>] NOP module names, for example: ['x86/single_byte']
@ -59,7 +59,7 @@ class RPC_Module < RPC_Base
end
# Returns a list of post module names.
# Returns a list of post module names. The 'post/' prefix will not be included.
#
# @return [Hash] A list of post module names. It contains the following key:
# * 'modules' [Array<string>] Post module names, for example: ['windows/wlan/wlan_profile']
@ -270,7 +270,7 @@ class RPC_Module < RPC_Base
# Returns a list of encoding formats.
#
# @return [Array] Encoding foramts.
# @return [Array<String>] Encoding foramts.
# @example Here's how you would use this from the client:
# rpc.call('module.encode_formats')
def rpc_encode_formats

View File

@ -73,7 +73,7 @@ class RPC_Session < RPC_Base
end
# Reads a shell session (such as a command output).
# Reads the output of a shell session (such as a command output).
#
# @note Shell read is now a positon-aware reader of the shell's associated
# ring buffer. For more direct control of the pointer into a ring
@ -107,7 +107,8 @@ class RPC_Session < RPC_Base
end
# Writes to a shell session (such as a command).
# Writes to a shell session (such as a command). Note that you will to manually add a newline at the
# enf of your input so the system will process it.
# You may want to use #rpc_shell_read to retrieve the output.
#
# @note shell_write is a wrapper of #rpc_ring_put.
@ -135,7 +136,7 @@ class RPC_Session < RPC_Base
# @param [String] lhost Local host.
# @param [Fixnum] lport Local port.
# @return [Hash] A hash indicating the actioin was successful. It contains the following key:
# 'result' [String] A message that says 'success'
# * 'result' [String] A message that says 'success'
# @example Here's how you would use this from the client:
# rpc.call('session.shell_upgrade', 2, payload_lhost, payload_lport)
def rpc_shell_upgrade( sid, lhost, lport)
@ -149,6 +150,9 @@ class RPC_Session < RPC_Base
# Reads the output from a meterpreter session (such as a command output).
#
# @note Multiple concurrent callers writing and reading the same Meterperter session can lead to
# a conflict, where one caller gets the others output and vice versa. Concurrent access to a
# Meterpreter session is best handled by post modules.
# @param [Fixnum] sid Session ID.
# @raise [Msf::RPC::Exception] An error that could be one of these:
# * 500 Session ID is unknown.
@ -215,7 +219,7 @@ class RPC_Session < RPC_Base
end
end
# Returns the last sequence.
# Returns the last sequence (last issued ReadPointer) for a shell session.
#
# @param [Fixnum] sid Session ID.
# @raise [Msf::RPC::Exception] An error that could be one of these:
@ -231,14 +235,13 @@ class RPC_Session < RPC_Base
end
# Clears the session.
# Clears a shell session. This may be useful to reclaim memory for idle background sessions.
#
# @param [Fixnum] sid Session ID.
# @raise [Msf::RPC::Exception] An error that could be one of these:
# * 500 Session ID is unknown.
# * 500 Invalid session type.
# @return [Hash] A hash indicating whether the action was successful or not.
# It contains the following key:
# @return [Hash] A hash indicating whether the action was successful or not. It contains:
# * 'result' [String] Either 'success' or 'failure'.
# @example Here's how you would use this from the client:
# rpc.call('session.ring_clear', 2)
@ -256,6 +259,9 @@ class RPC_Session < RPC_Base
# Sends an input to a meterpreter prompt.
# You may want to use #rpc_meterpreter_read to retrieve the output.
#
# @note Multiple concurrent callers writing and reading the same Meterperter session can lead to
# a conflict, where one caller gets the others output and vice versa. Concurrent access to a
# Meterpreter session is best handled by post modules.
# @param [Fixnum] sid Session ID.
# @param [String] data Input to the meterpreter prompt.
# @raise [Msf::RPC::Exception] An error that could be one of these:
@ -286,14 +292,13 @@ class RPC_Session < RPC_Base
end
# Detaches from a meterpreter session.
# Detaches from a meterpreter session. Serves the same purpose as [CTRL]+[Z].
#
# @param [Fixnum] sid Session ID.
# @raise [Msf::RPC::Exception] An error that could be one of these:
# * 500 Session ID is unknown.
# * 500 Invalid session type.
# @return [Hash] A hash indicating the action was successful or not.
# It contains the following key:
# @return [Hash] A hash indicating the action was successful or not. It contains:
# * 'result' [String] Either 'success' or 'failure'.
# @example Here's how you would use this from the client:
# rpc.call('session.meterpreter_session_detach', 3)
@ -309,7 +314,7 @@ class RPC_Session < RPC_Base
end
# Kills a meterpreter session.
# Kills a meterpreter session. Serves the same purpose as [CTRL]+[C]
#
# @param [Fixnum] sid Session ID.
# @raise [Msf::RPC::Exception] An error that could be one of these: