Class: Ronin::DB::HTTPRequest

Inherits:
ActiveRecord::Base
  • Object
show all
Includes:
Model
Defined in:
lib/ronin/db/http_request.rb

Overview

Represents a HTTP request.

Instance Attribute Summary collapse

Method Summary

Methods included from Model

included

Instance Attribute Details

#bodyString?

The optional body of the HTTP request.

Returns:

  • (String, nil)


96
# File 'lib/ronin/db/http_request.rb', line 96

attribute :body, :text

#created_atTime

When the HTTP request was created.

Returns:

  • (Time)


117
# File 'lib/ronin/db/http_request.rb', line 117

attribute :created_at, :datetime

#headersArray<HTTPRequestHeader>

The additional headers of HTTP request.

Returns:



102
103
104
# File 'lib/ronin/db/http_request.rb', line 102

has_many :headers, foreign_key: 'request_id',
class_name:  'HTTPRequestHeader',
dependent:   :destroy

#idInteger

The primary ID for the HTTP request.

Returns:

  • (Integer)


39
# File 'lib/ronin/db/http_request.rb', line 39

attribute :id, :integer

#pathString

The path of the HTTP request.

Returns:

  • (String)


76
# File 'lib/ronin/db/http_request.rb', line 76

attribute :path, :string

#queryString?

The query string of the HTTP request.

Returns:

  • (String, nil)


83
# File 'lib/ronin/db/http_request.rb', line 83

attribute :query, :string

#query_paramsArray<HTTPQueryParam>

The additional parsed query params of the HTTP request.

Returns:



89
90
91
# File 'lib/ronin/db/http_request.rb', line 89

has_many :query_params, foreign_key: 'request_id',
class_name: 'HTTPQueryParam',
dependent:  :destroy

#request_method"copy", ...

The request method.

Returns:

  • ("copy", "delete", "get", "head", "lock", "mkcol", "move", "options", "patch", "post", "propfind", "proppatch", "put", "trace", "unlock")


53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# File 'lib/ronin/db/http_request.rb', line 53

enum request_method: {
  copy:      'COPY',
  delete:    'DELETE',
  get:       'GET',
  head:      'HEAD',
  lock:      'LOCK',
  mkcol:     'MKCOL',
  move:      'MOVE',
  options:   'OPTIONS',
  patch:     'PATCH',
  post:      'POST',
  propfind:  'PROPFIND',
  proppatch: 'PROPPATCH',
  put:       'PUT',
  trace:     'TRACE',
  unlock:    'UNLOCK'
}, _suffix: :request

#responseHTTPResponse?

The optional HTTP response associated with the HTTP request.

Returns:



110
111
# File 'lib/ronin/db/http_request.rb', line 110

belongs_to :response, class_name: 'HTTPResponse',
dependent:  :destroy

#source_ipString?

The source IP Address.

Returns:

  • (String, nil)


123
# File 'lib/ronin/db/http_request.rb', line 123

attribute :source_ip, :string

#versionString

The HTTP version of the HTTP request.

Returns:

  • (String)


45
# File 'lib/ronin/db/http_request.rb', line 45

attribute :version, :string