Extract Msf::Module::Failure

MSP-11126

Move `Msf::Module::Failure` to a file of its own.
bug/bundler_fix
Luke Imhoff 2014-10-15 15:52:26 -05:00
parent 98a56d594a
commit 370daaed5e
No known key found for this signature in database
GPG Key ID: 5B1FB01FB33356F8
2 changed files with 42 additions and 72 deletions

View File

@ -12,6 +12,7 @@ module Msf
#
###
class Module
autoload :Failure, 'msf/core/module/failure'
# Modules can subscribe to a user-interface, and as such they include the
# UI subscriber module. This provides methods like print, print_line, etc.
@ -731,78 +732,6 @@ class Module
raise RuntimeError, "#{reason.to_s}: #{msg}"
end
#
# Constants indicating the reason for an unsuccessful module attempt
#
module Failure
#
# No confidence in success or failure
#
None = 'none'
#
# No confidence in success or failure
#
Unknown = 'unknown'
#
# The network service was unreachable (connection refused, etc)
#
Unreachable = 'unreachable'
#
# The exploit settings were incorrect
#
BadConfig = 'bad-config'
#
# The network service disconnected us mid-attempt
#
Disconnected = 'disconnected'
#
# The application endpoint or specific service was not found
#
NotFound = 'not-found'
#
# The application replied in an unexpected fashion
#
UnexpectedReply = 'unexpected-reply'
#
# The exploit triggered some form of timeout
#
TimeoutExpired = 'timeout-expired'
#
# The exploit was interrupted by the user
#
UserInterrupt = 'user-interrupt'
#
# The application replied indication we do not have access
#
NoAccess = 'no-access'
#
# The target is not compatible with this exploit or settings
#
NoTarget = 'no-target'
#
# The application response indicated it was not vulnerable
#
NotVulnerable = 'not-vulnerable'
#
# The payload was delivered but no session was opened (AV, network, etc)
#
PayloadFailed = 'payload-failed'
end
##
#
# Just some handy quick checks

View File

@ -0,0 +1,41 @@
# Constants indicating the reason for an unsuccessful module attempt
module Msf::Module::Failure
# The exploit settings were incorrect
BadConfig = 'bad-config'
# The network service disconnected us mid-attempt
Disconnected = 'disconnected'
# The application replied indication we do not have access
NoAccess = 'no-access'
# No confidence in success or failure
None = 'none'
# The target is not compatible with this exploit or settings
NoTarget = 'no-target'
# The application endpoint or specific service was not found
NotFound = 'not-found'
# The application response indicated it was not vulnerable
NotVulnerable = 'not-vulnerable'
# The payload was delivered but no session was opened (AV, network, etc)
PayloadFailed = 'payload-failed'
# The exploit triggered some form of timeout
TimeoutExpired = 'timeout-expired'
# The application replied in an unexpected fashion
UnexpectedReply = 'unexpected-reply'
# No confidence in success or failure
Unknown = 'unknown'
# The network service was unreachable (connection refused, etc)
Unreachable = 'unreachable'
# The exploit was interrupted by the user
UserInterrupt = 'user-interrupt'
end