Correct YARD doc comments
parent
cecc8aba2c
commit
4ba761986f
|
@ -79,7 +79,7 @@ class Metasploit::Framework::CredentialCollection
|
|||
# Adds a string as an addition private credential
|
||||
# to be combined in the collection.
|
||||
#
|
||||
# @param [String] :private_str the string to use as a private
|
||||
# @param [String] private_str the string to use as a private
|
||||
# @return [void]
|
||||
def add_private(private_str='')
|
||||
additional_privates << private_str
|
||||
|
@ -88,7 +88,7 @@ class Metasploit::Framework::CredentialCollection
|
|||
# Adds a string as an addition public credential
|
||||
# to be combined in the collection.
|
||||
#
|
||||
# @param [String] :public_str the string to use as a public
|
||||
# @param [String] public_str the string to use as a public
|
||||
# @return [void]
|
||||
def add_public(public_str='')
|
||||
additional_publics << public_str
|
||||
|
|
|
@ -22,7 +22,7 @@ module Metasploit
|
|||
#
|
||||
# @param options [Hash{Symbol=>String}]
|
||||
# @option options [String] :path Path to use instead of first element of {configurations_pathnames}
|
||||
# @return [Pathname] if configuration pathname exists.
|
||||
# @return [String] pathname if configuration pathname exists.
|
||||
# @return [nil] if configuration pathname does not exist.
|
||||
def self.configurations_pathname(options={})
|
||||
options.assert_valid_keys(:path)
|
||||
|
|
|
@ -189,7 +189,7 @@ module Metasploit
|
|||
|
||||
# Sends a HTTP request with Rex
|
||||
#
|
||||
# @param [Hash] Native support includes the following (also see Rex::Proto::Http::Request#request_cgi)
|
||||
# @param [Hash] opts native support includes the following (also see Rex::Proto::Http::Request#request_cgi)
|
||||
# @option opts[String] 'host' The remote host
|
||||
# @option opts[Fixnum] 'port' The remote port
|
||||
# @option opts[Boolean] 'ssl' The SSL setting, TrueClass or FalseClass
|
||||
|
@ -356,7 +356,7 @@ module Metasploit
|
|||
|
||||
# Combine the base URI with the target URI in a sane fashion
|
||||
#
|
||||
# @param [String] The target URL
|
||||
# @param [String] target_uri the target URL
|
||||
# @return [String] the final URL mapped against the base
|
||||
def normalize_uri(target_uri)
|
||||
(self.uri.to_s + "/" + target_uri.to_s).gsub(/\/+/, '/')
|
||||
|
|
|
@ -29,7 +29,7 @@ module Metasploit
|
|||
|
||||
# Returns the latest sid from Symantec Web Gateway.
|
||||
#
|
||||
# @returns [String] The PHP Session ID for Symantec Web Gateway login
|
||||
# @return [String] The PHP Session ID for Symantec Web Gateway login
|
||||
def get_last_sid
|
||||
@last_sid ||= lambda {
|
||||
# We don't have a session ID. Well, let's grab one right quick from the login page.
|
||||
|
|
|
@ -108,9 +108,9 @@ module Auxiliary::AuthBrute
|
|||
# This method takes a {Metasploit::Framework::CredentialCollection} and prepends existing SSHKeys
|
||||
# from the database. This allows the users to use the DB_ALL_CREDS option.
|
||||
#
|
||||
# @param cred_collection [Metasploit::Framework::CredentialCollection]
|
||||
# @param [Metasploit::Framework::CredentialCollection] cred_collection
|
||||
# the credential collection to add to
|
||||
# @return [Metasploit::Framework::CredentialCollection] the modified Credentialcollection
|
||||
# @return [Metasploit::Framework::CredentialCollection] cred_collection the modified Credentialcollection
|
||||
def prepend_db_keys(cred_collection)
|
||||
if prepend_db_creds?
|
||||
each_ssh_cred do |cred|
|
||||
|
@ -140,8 +140,8 @@ module Auxiliary::AuthBrute
|
|||
# {Metasploit::Framework::CredentialCollection} as dictated by the
|
||||
# selected datastore options.
|
||||
#
|
||||
# @param [Metasploit::Framework::CredentialCollection] the credential collection to add to
|
||||
# @param [Metasploit::Credential::Core] the Credential Core to process
|
||||
# @param [Metasploit::Framework::CredentialCollection] cred_collection the credential collection to add to
|
||||
# @param [Metasploit::Credential::Core] cred the credential to process
|
||||
def process_cred_for_collection(cred_collection, cred)
|
||||
msf_cred = cred.to_credential
|
||||
cred_collection.prepend_cred(msf_cred) if datastore['DB_ALL_CREDS']
|
||||
|
|
|
@ -77,7 +77,7 @@ module Auxiliary::JohnTheRipper
|
|||
end
|
||||
|
||||
# This method instantiates a {Metasploit::Framework::JtR::Wordlist}, writes the data
|
||||
# out to a file and returns the {rex::quickfile} object.
|
||||
# out to a file and returns the {Rex::Quickfile} object.
|
||||
#
|
||||
# @return [nilClass] if there is no active framework db connection
|
||||
# @return [Rex::Quickfile] if it successfully wrote the wordlist to a file
|
||||
|
|
|
@ -61,7 +61,7 @@ module Auxiliary::Report
|
|||
# This method safely get the workspace ID. It handles if the db is not active
|
||||
#
|
||||
# @return [NilClass] if there is no DB connection
|
||||
# @return [Fixnum] the ID of the current {Mdm::Workspace}
|
||||
# @return [Fixnum] the ID of the current {::Mdm::Workspace}
|
||||
def myworkspace_id
|
||||
if framework.db.active
|
||||
myworkspace.id
|
||||
|
@ -115,7 +115,7 @@ module Auxiliary::Report
|
|||
# Report a client connection
|
||||
#
|
||||
# opts must contain
|
||||
# :host the address of the client connecting
|
||||
# :host the address of the client connecting
|
||||
# :ua_string a string that uniquely identifies this client
|
||||
# opts can contain
|
||||
# :ua_name a brief identifier for the client, e.g. "Firefox"
|
||||
|
@ -161,7 +161,7 @@ module Auxiliary::Report
|
|||
# by a module. This method is deprecated and the new Metasploit::Credential methods
|
||||
# should be used directly instead.
|
||||
#
|
||||
# @param :opts [Hash] the option hash
|
||||
# @param opts [Hash] the option hash
|
||||
# @option opts [String] :host the address of the host (also takes a {Mdm::Host})
|
||||
# @option opts [Fixnum] :port the port of the connected service
|
||||
# @option opts [Mdm::Service] :service an optional Service object to build the cred for
|
||||
|
|
|
@ -35,7 +35,7 @@ module Exploit::Remote::SMB::Client::Psexec
|
|||
# Retrieve the SERVICE_NAME option, generate a random
|
||||
# one if not already set.
|
||||
#
|
||||
# @return service_name [String] the name of the service.
|
||||
# @return [String] service_name the name of the service.
|
||||
def service_name
|
||||
@service_name ||= datastore['SERVICE_NAME']
|
||||
@service_name ||= Rex::Text.rand_text_alpha(8)
|
||||
|
@ -44,7 +44,7 @@ module Exploit::Remote::SMB::Client::Psexec
|
|||
# Retrieve the SERVICE_DISPLAY_NAME option, generate a random
|
||||
# one if not already set.
|
||||
#
|
||||
# @return service_display_name [String] the display name of the service.
|
||||
# @return [String] service_display_name the display name of the service.
|
||||
def display_name
|
||||
@display_name ||= datastore['SERVICE_DISPLAY_NAME']
|
||||
@display_name ||= Rex::Text.rand_text_alpha(16)
|
||||
|
@ -52,7 +52,7 @@ module Exploit::Remote::SMB::Client::Psexec
|
|||
|
||||
# Retrieve the SERVICE_DESCRIPTION option
|
||||
#
|
||||
# @return service_description [String] the service description.
|
||||
# @return [String] service_description the service description.
|
||||
def service_description
|
||||
@service_description ||= datastore['SERVICE_DESCRIPTION']
|
||||
end
|
||||
|
|
|
@ -22,6 +22,7 @@ module Exploit::Remote::TcpServer
|
|||
# OptEnum.new('SSLVersion', [ false, 'Specify the version of SSL that should be used', 'TLS1', ['SSL2', 'SSL3', 'TLS1']]),
|
||||
OptPath.new('SSLCert', [ false, 'Path to a custom SSL certificate (default is randomly generated)']),
|
||||
OptAddress.new('SRVHOST', [ true, "The local host to listen on. This must be an address on the local machine or 0.0.0.0", '0.0.0.0' ]),
|
||||
#OptAddress.new('SRVHOST', [ true, "The local host to listen on. This must be an address on the local machine or 0.0.0.0", "#{Rex::Socket.source_address}" ]),
|
||||
OptPort.new('SRVPORT', [ true, "The local port to listen on.", 8080 ]),
|
||||
|
||||
], Msf::Exploit::Remote::TcpServer)
|
||||
|
|
|
@ -99,7 +99,7 @@ module ReverseHttp
|
|||
"#{scheme}://#{callback_host}/"
|
||||
end
|
||||
|
||||
# Use the {#refname} to determine whether this handler uses SSL or not
|
||||
# Use the refname to determine whether this handler uses SSL or not
|
||||
#
|
||||
def ssl?
|
||||
!!(self.refname.index("https"))
|
||||
|
|
|
@ -54,9 +54,9 @@ module Msf
|
|||
end
|
||||
|
||||
# Identifies a valid SQL Server command line client on the host and sets
|
||||
# @sql_client
|
||||
# sql_client
|
||||
#
|
||||
# @see #sql_client
|
||||
# @see sql_client
|
||||
# @return [String, nil] the SQL command line client
|
||||
def get_sql_client
|
||||
client = nil
|
||||
|
|
|
@ -528,7 +528,7 @@ module Services
|
|||
# Parses out a SERVICE_STATUS struct from the
|
||||
# lpServiceStatus out parameter
|
||||
#
|
||||
# @param (lpServiceStatus)
|
||||
# @param (lpServiceStatus) lpServiceStatus latest status of calling service
|
||||
#
|
||||
# @return [Hash] Containing SERVICE_STATUS values
|
||||
#
|
||||
|
|
|
@ -49,8 +49,8 @@ module Msf::HTTP::JBoss::Base
|
|||
|
||||
# Try to auto detect the target architecture and platform
|
||||
#
|
||||
# @param [Array] The available targets
|
||||
# @return [Msf::Module::Target, nil] The detected target or nil
|
||||
# @param [Array] available_targets The available targets
|
||||
# @return [Msf::Module::Target, nil] java_targets The detected target or nil
|
||||
def auto_target(available_targets)
|
||||
if http_verb == 'HEAD'
|
||||
print_status("Sorry, automatic target detection doesn't work with HEAD requests")
|
||||
|
|
|
@ -7,7 +7,7 @@ module Msf::HTTP::JBoss::DeploymentFileRepositoryScripts
|
|||
# to overcome the size limit in those requests
|
||||
#
|
||||
# @param stager_base [String] The name of the base of the stager.
|
||||
# @param stager_jsp [String] The name name of the jsp stager.
|
||||
# @param stager_jsp_name [String] The name name of the jsp stager.
|
||||
# @return [String] The JSP head stager.
|
||||
def head_stager_jsp(stager_base, stager_jsp_name)
|
||||
content_var = Rex::Text.rand_text_alpha(8+rand(8))
|
||||
|
|
|
@ -9,7 +9,7 @@ module Msf
|
|||
# Builds a Rex::Java::Serialization::Model::Stream to make
|
||||
# a JMX handshake with an endpoint
|
||||
#
|
||||
# @param id [String] The endpoint UnicastRef ObjId
|
||||
# @param obj_id [String] The endpoint UnicastRef ObjId
|
||||
# @return [Rex::Java::Serialization::Model::Stream]
|
||||
def handshake_stream(obj_id)
|
||||
block_data = Rex::Java::Serialization::Model::BlockData.new(nil, "#{obj_id}\xff\xff\xff\xff\xf0\xe0\x74\xea\xad\x0c\xae\xa8")
|
||||
|
|
|
@ -109,8 +109,8 @@ module Msf
|
|||
|
||||
# Helper method to read fragmented data from a ```Rex::Socket::Tcp```
|
||||
#
|
||||
# @param opts [Hash]
|
||||
# @option opts [Rex::Socket::Tcp] :sock
|
||||
# @param [Hash] nsock
|
||||
# @option [Rex::Socket::Tcp] sock
|
||||
# @return [String]
|
||||
def safe_get_once(nsock = sock)
|
||||
data = ''
|
||||
|
|
|
@ -33,7 +33,7 @@ module Msf
|
|||
|
||||
# Builds a MIT Credential Cache principal
|
||||
#
|
||||
# @param opts [Hash<{Symbol => <Fixnum, String, Array<String>}>]
|
||||
# @param opts [Hash<{Symbol => <Fixnum, String, Array<String>>}>]
|
||||
# @option opts [Fixnum] :name_type
|
||||
# @option opts [String] :realm
|
||||
# @option opts [Array<String>] :components
|
||||
|
|
|
@ -32,7 +32,7 @@ module Rex
|
|||
#
|
||||
# @param io [IO] the io to read from
|
||||
# @return [self] if deserialization succeeds
|
||||
# @faise [RuntimeError] if deserialization doesn't succeed
|
||||
# @return [RuntimeError] false if deserialization doesn't succeed
|
||||
def decode(io)
|
||||
code = io.read(1)
|
||||
|
||||
|
|
|
@ -190,8 +190,7 @@ module Rex
|
|||
|
||||
# Serializes an NewArray value
|
||||
#
|
||||
# @param value [Fixnum] the value to serialize
|
||||
# @param value [Float] the value to serialize
|
||||
# @param value [Fixnum, Float] the value to serialize
|
||||
# @return [String] the serialized value
|
||||
# @raise [RuntimeError] if serialization fails
|
||||
def encode_value(value)
|
||||
|
|
|
@ -63,7 +63,7 @@ module Rex
|
|||
|
||||
# Adds an element to the references array
|
||||
#
|
||||
# @param io [Rex::Java::Serialization::Model::Element] the object to save as reference dst
|
||||
# @param ref [Rex::Java::Serialization::Model::Element] the object to save as reference dst
|
||||
def add_reference(ref)
|
||||
self.references.push(ref)
|
||||
end
|
||||
|
@ -120,4 +120,4 @@ module Rex
|
|||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -187,7 +187,7 @@ module Rex
|
|||
|
||||
# Decodes a Kerberos response
|
||||
#
|
||||
# @param input [String] the raw response message
|
||||
# @param data [String] the raw response message
|
||||
# @return [<Rex::Proto::Kerberos::Model::KrbError, Rex::Proto::Kerberos::Model::KdcResponse>] the kerberos message response
|
||||
# @raise [RuntimeError] if the response can't be processed
|
||||
def decode_kerb_response(data)
|
||||
|
|
|
@ -1,8 +1,3 @@
|
|||
##
|
||||
# $Id$
|
||||
# $Revision$
|
||||
##
|
||||
|
||||
require 'rex/ui/text/table'
|
||||
|
||||
module Msf
|
||||
|
|
Loading…
Reference in New Issue