Exception: Metasploit::Framework::DataService::Remote::HttpError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/metasploit/framework/data_service/remote/http/error.rb

Direct Known Subclasses

ClientError, NotFound, ServerError

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(error:, status_code:, message: 'Unknown Error') ⇒ HttpError

Returns a new instance of HttpError.



7
8
9
10
11
# File 'lib/metasploit/framework/data_service/remote/http/error.rb', line 7

def initialize(error:, status_code:, message: 'Unknown Error')
  super(message)
  @error = error
  @status_code = status_code
end

Instance Attribute Details

#errorObject (readonly)

Returns the value of attribute error.



13
14
15
# File 'lib/metasploit/framework/data_service/remote/http/error.rb', line 13

def error
  @error
end

#status_codeObject (readonly)

Returns the value of attribute status_code.



13
14
15
# File 'lib/metasploit/framework/data_service/remote/http/error.rb', line 13

def status_code
  @status_code
end