rabid 0.0.3 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +2 -1
  3. data/bin/rabid +6 -14
  4. data/lib/bigipcookie/version.rb +1 -1
  5. data/lib/bigipcookie.rb +33 -30
  6. metadata +21 -181
  7. data/.gitignore +0 -8
  8. data/.rubocop.yml +0 -22
  9. data/.yardopts +0 -4
  10. data/.yardopts-dev +0 -6
  11. data/Gemfile +0 -6
  12. data/Gemfile.lock +0 -56
  13. data/README.md +0 -31
  14. data/Rakefile +0 -10
  15. data/bin/rabid_setup +0 -6
  16. data/docs/.nojekyll +0 -0
  17. data/docs/About.md +0 -13
  18. data/docs/CHANGELOG.md +0 -13
  19. data/docs/README.md +0 -23
  20. data/docs/_coverpage.md +0 -14
  21. data/docs/_media/logo.png +0 -0
  22. data/docs/_navbar.md +0 -2
  23. data/docs/_sidebar.md +0 -15
  24. data/docs/index.html +0 -31
  25. data/docs/pages/demo.md +0 -3
  26. data/docs/pages/documentation.md +0 -34
  27. data/docs/pages/install.md +0 -90
  28. data/docs/pages/publishing.md +0 -39
  29. data/docs/pages/quick-start.md +0 -30
  30. data/docs/pages/usage.md +0 -54
  31. data/docs/vendor/docsify.js +0 -1
  32. data/docs/vendor/plugins/emoji.min.js +0 -1
  33. data/docs/vendor/plugins/search.min.js +0 -1
  34. data/docs/vendor/prismjs/components/prism-ruby.min.js +0 -1
  35. data/docs/vendor/themes/vue.css +0 -1
  36. data/docs/why.md +0 -47
  37. data/docs/yard/BigIPCookie/Decode.html +0 -782
  38. data/docs/yard/BigIPCookie.html +0 -159
  39. data/docs/yard/Version.html +0 -126
  40. data/docs/yard/_index.html +0 -138
  41. data/docs/yard/class_list.html +0 -51
  42. data/docs/yard/css/common.css +0 -1
  43. data/docs/yard/css/full_list.css +0 -58
  44. data/docs/yard/css/style.css +0 -496
  45. data/docs/yard/file.LICENSE.html +0 -70
  46. data/docs/yard/file.README.html +0 -105
  47. data/docs/yard/file_list.html +0 -61
  48. data/docs/yard/frames.html +0 -17
  49. data/docs/yard/index.html +0 -105
  50. data/docs/yard/js/app.js +0 -303
  51. data/docs/yard/js/full_list.js +0 -216
  52. data/docs/yard/js/jquery.js +0 -4
  53. data/docs/yard/method_list.html +0 -99
  54. data/docs/yard/top-level-namespace.html +0 -112
  55. data/package-lock.json +0 -154
  56. data/test/test_bigipcookie.rb +0 -65
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1fb66b7c9b3281ef662bdd6dc6c65e6ed5093e490f15e9aaa999332bad9154f9
4
- data.tar.gz: c483b97746a73410651ddc054b17ee70cd49c1f018231a1f274159d3530b16b0
3
+ metadata.gz: d555b0fb7ccdcb1d5267d705b5f71466c6cc42de639a7f688dfbb2a0be3fea0f
4
+ data.tar.gz: 7b3b2d24ead8bd3b7c8eb00cc5e2cfbccb4242744a4d4ee8792c09514909c643
5
5
  SHA512:
6
- metadata.gz: 4eef5f2d9387f6d939e1950e55599a21817eee083d1715a33167aba68bc5cc9bdbf2ce0f5cb7128bb041ddea4d3d37a9cf9f2502fb36583c40474aaf4de98264
7
- data.tar.gz: 974535723fa1b1c0ee77ca6f2b868fb7cf51f2db4ec63f93dbb5a2d20f55cef1c75385fbf4a67df0a1cc18700c2a215425d5283c5dde169d749ccc47305e7c95
6
+ metadata.gz: 524c49aa51bd05b7ef980b5232bbb0241b2a3ce8e8f56ab4106c20ad5e180048789d1982e3db16b52a83108b8ecaec82493833f713966224d209fc648d6babee
7
+ data.tar.gz: a72649dfb1744031c757c8460cc126ee372fba351e124e93c56d6b3529c077369531060b6921ceae3a3b74ef619d8ce22ddc5fa0d3759ef0190aced862f9143b
data/LICENSE.txt CHANGED
@@ -1,6 +1,7 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2019 Alexandre ZANNI
3
+ Copyright (c) 2020-2020 Alexandre ZANNI
4
+ Copyright (c) 2019-2020 Alexandre ZANNI at Orange Cyberdefense
4
5
 
5
6
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
7
  of this software and associated documentation files (the "Software"), to deal
data/bin/rabid CHANGED
@@ -35,6 +35,7 @@ DOCOPT
35
35
 
36
36
  begin
37
37
  args = Docopt.docopt(doc, version: BigIPCookie::VERSION)
38
+ Paint.mode = 0 if args['--no-color']
38
39
  pp args if args['--debug']
39
40
  # use case 1, using the tool
40
41
  if args['<raw_cookie>']
@@ -43,22 +44,13 @@ begin
43
44
  opts[:ipv6compression] = 0 if args['--ipv6-long-format']
44
45
  bip.auto_decode(opts)
45
46
  # Display
46
- if args['--no-color']
47
- if args['--short']
48
- puts bip.decoded_cookie
49
- else
50
- puts "Pool name: #{bip.pool_name}"
51
- puts "Cookie type: #{bip.cookie_type}"
52
- puts "Raw cookie: #{bip.raw_cookie}"
53
- puts "Decoded cookie: #{bip.decoded_cookie}"
54
- end
55
- elsif args['--short']
47
+ if args['--short']
56
48
  puts Paint[bip.decoded_cookie, :green]
57
49
  else
58
- puts Paint['Pool name:', :white, :bold] + ' ' + bip.pool_name
59
- puts Paint['Cookie type:', :white, :bold] + ' ' + bip.cookie_type
60
- puts Paint['Raw cookie:', :white, :bold] + ' ' + bip.raw_cookie
61
- puts Paint['Decoded cookie:', :white, :bold] + ' ' + Paint[bip.decoded_cookie, :green]
50
+ puts "#{Paint['Pool name:', :white, :bold]} #{bip.pool_name}"
51
+ puts "#{Paint['Cookie type:', :white, :bold]} #{bip.cookie_type}"
52
+ puts "#{Paint['Raw cookie:', :white, :bold]} #{bip.raw_cookie}"
53
+ puts "#{Paint['Decoded cookie:', :white, :bold]} #{Paint[bip.decoded_cookie, :green]}"
62
54
  end
63
55
  end
64
56
  # use case 2, help: already handled by docopt
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Version
4
- VERSION = '0.0.3'
4
+ VERSION = '0.1.0'
5
5
  end
data/lib/bigipcookie.rb CHANGED
@@ -51,25 +51,25 @@ class BigIPCookie
51
51
  # @!visibility public
52
52
  # @param ip [String] the encoded IP address
53
53
  # @param opts [Hash] options for the decoding process (only
54
- # :ipv6compression should be used, others are for developers)
55
- # @option opts [Integer] :default default behavior, default value is 1, if
56
- # value is set to 0 it disables :ip2hex and :reverse
57
- # @option opts [Integer] :ipversion 4 for IPv4 and 6 for IPv6, default is 4,
58
- # 4 set :joinchar to '.' and :scanby to 2, 6 set :joinchar to ':' and
59
- # :scanby to 6
54
+ # `:ipv6compression` should be used, others are for developers)
55
+ # @option opts [Integer] :default default behavior, default value is `1`, if
56
+ # value is set to `0` it disables `:ip2hex` and `:reverse`
57
+ # @option opts [Integer] :ipversion `4` for IPv4 and `6` for IPv6, default is `4`,
58
+ # `4` sets `:joinchar` to `.` and `:scanby` to `2`, `6` sets `:joinchar` to `:` and
59
+ # `:scanby` to `6`
60
60
  # @option opts [Integer] :ip2hex encode IP address groups into hexadecimal,
61
- # default is 1, set to 0 disable
61
+ # default is `1`, set to `0` disable
62
62
  # @option opts [Integer] :joinchar the character used to join the IP
63
- # address groups, default is '.' (IPv4), for example it can be set to
64
- # ':' for IPv6
63
+ # address groups, default is `.` (IPv4), for example it can be set to
64
+ # `:` for IPv6
65
65
  # @option opts [Integer] :hex2ip decode hexadecimal IP address groups to
66
- # decimal, default is 1, set 0 to disable
67
- # @option opts [Integer] :reverse reverse the IP address groups if set to 1,
68
- # default is 1
69
- # @option opts [Integer] :ipv6compression compress IPv6 address if set to 1,
70
- # default is 1
66
+ # decimal, default is `1`, set `0` to disable
67
+ # @option opts [Integer] :reverse reverse the IP address groups if set to `1`,
68
+ # default is `1`
69
+ # @option opts [Integer] :ipv6compression compress IPv6 address if set to `1`,
70
+ # default is `1`
71
71
  # @option opts [Integer] :scanby parse the raw cookie value by n to find IP
72
- # address groups, default is 2 for IPv4 and 4 for IPv6
72
+ # address groups, default is `2` for IPv4 and `4` for IPv6
73
73
  # @return [String] the decoded IP address
74
74
  def decode_ip(ip, opts = {})
75
75
  opts[:default] ||= 1
@@ -85,15 +85,17 @@ class BigIPCookie
85
85
  opts[:reverse] = 0
86
86
  end
87
87
 
88
- if opts[:ipversion] == 4
88
+ case opts[:ipversion]
89
+ when 4
89
90
  opts[:joinchar] = '.'
90
91
  opts[:scanby] = 2
91
- elsif opts[:ipversion] == 6
92
+ when 6
92
93
  opts[:joinchar] = ':'
93
94
  opts[:scanby] = 4
94
95
  end
95
96
 
96
97
  ip = format('%02x', ip) if opts[:ip2hex] == 1 # ip to hex
98
+ ip = "0#{ip}" if ip.size.odd? # prepend a 0 when we have an odd number
97
99
  ip = ip.scan(/.{#{opts[:scanby]}}/) # split by n
98
100
  ip.reverse! if opts[:reverse] == 1 # reverse array
99
101
  ip = ip.map { |i| i.to_i(16) } if opts[:hex2ip] == 1 # hex to ip
@@ -165,9 +167,9 @@ class BigIPCookie
165
167
  end
166
168
 
167
169
  # Return that the cookie is encrypted
168
- # @param cookie [String] raw cookie value
170
+ # @param _cookie [String] raw cookie value
169
171
  # @return [String] Encrypted cookie detection message
170
- def encrypted(cookie)
172
+ def encrypted(_cookie)
171
173
  return 'Unknown:Encrypted'
172
174
  end
173
175
 
@@ -176,7 +178,7 @@ class BigIPCookie
176
178
  # @return [Integer] detected cookie code (mapped with {decode_cookie})
177
179
  def detect_cookie_type(cookie)
178
180
  ## IPv4 pool members
179
- return 400 if /[0-9]{10}\.[0-9]{5}\.0000/.match?(cookie)
181
+ return 400 if /[0-9]{1,10}\.[0-9]{1,7}\.0000/.match?(cookie)
180
182
 
181
183
  ## IPv4 pool members in non-default route domains
182
184
  return 401 if /rd([0-9]+)o00000000000000000000ffff([0-9a-zA-Z]{8})o
@@ -189,7 +191,7 @@ class BigIPCookie
189
191
  return 601 if /rd([0-9]+)o([0-9a-zA-Z]{32})o([0-9]{1,5})/.match?(cookie)
190
192
 
191
193
  ## Encrypted
192
- return 999 if /!(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?/.match?(cookie)
194
+ return 999 if %r{!(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?}.match?(cookie)
193
195
 
194
196
  raise 'Unrecognized cookie'
195
197
  end
@@ -200,19 +202,20 @@ class BigIPCookie
200
202
  # @return [String] the decoded cookie value
201
203
  def decode_cookie(cookie, opts = {})
202
204
  number = detect_cookie_type(cookie)
203
- if number == 400
205
+ case number
206
+ when 400
204
207
  @cookie_type = 'IPv4 pool members'
205
208
  ipv4_pm(cookie)
206
- elsif number == 401
209
+ when 401
207
210
  @cookie_type = 'IPv4 pool members in non-default route domains'
208
211
  ipv4_pm_ndrd(cookie)
209
- elsif number == 600
212
+ when 600
210
213
  @cookie_type = 'IPv6 pool members'
211
214
  ipv6_pm(cookie, opts)
212
- elsif number == 601
215
+ when 601
213
216
  @cookie_type = 'IPv6 pool members in non-default route domains'
214
217
  ipv6_pm_ndrd(cookie, opts)
215
- elsif number == 999
218
+ when 999
216
219
  @cookie_type = 'Encrypted'
217
220
  encrypted(cookie)
218
221
  else
@@ -224,7 +227,7 @@ class BigIPCookie
224
227
  # cookie name is used or if no cookie key was provided
225
228
  # @return the pool name
226
229
  def retrieve_pool_name
227
- pool_name = /BIGipServer(.+)=.+/.match(@raw_cookie).captures[0]
230
+ pool_name = /BIGipServer(.*?)=.+/.match(@raw_cookie).captures[0]
228
231
  return pool_name
229
232
  end
230
233
 
@@ -234,14 +237,14 @@ class BigIPCookie
234
237
  # @note
235
238
  # .yardopts-dev must be used to get {decode_ip} documentation
236
239
  def auto_decode(opts = {})
237
- if /\=/.match?(@raw_cookie) # if there is a key
240
+ if /=/.match?(@raw_cookie) # if there is a key
238
241
  if /^BIGipServer/.match?(@raw_cookie) # if default cookie name
239
242
  pool_name = retrieve_pool_name
240
- cookie_value = /^BIGipServer.+=(.+)/.match(@raw_cookie).captures[0]
243
+ cookie_value = /^BIGipServer.*?=(.+)/.match(@raw_cookie).captures[0]
241
244
  decoded_cookie = decode_cookie(cookie_value, opts)
242
245
  @pool_name = pool_name
243
246
  else # custom cookie name
244
- cookie_value = /.+=(.+)/.match(@raw_cookie).captures[0]
247
+ cookie_value = /.*?=(.+)/.match(@raw_cookie).captures[0]
245
248
  decoded_cookie = decode_cookie(cookie_value, opts)
246
249
  @pool_name = 'unknown'
247
250
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rabid
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexandre ZANNI
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-10-03 00:00:00.000000000 Z
11
+ date: 2022-01-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: docopt
@@ -30,218 +30,58 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '2.1'
33
+ version: '2.2'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '2.1'
41
- - !ruby/object:Gem::Dependency
42
- name: bundler
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: '2.0'
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: '2.0'
55
- - !ruby/object:Gem::Dependency
56
- name: commonmarker
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: '0.20'
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '0.20'
69
- - !ruby/object:Gem::Dependency
70
- name: github-markup
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '3.0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '3.0'
83
- - !ruby/object:Gem::Dependency
84
- name: minitest
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - "~>"
88
- - !ruby/object:Gem::Version
89
- version: '5.11'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - "~>"
95
- - !ruby/object:Gem::Version
96
- version: '5.11'
97
- - !ruby/object:Gem::Dependency
98
- name: rake
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '12.3'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '12.3'
111
- - !ruby/object:Gem::Dependency
112
- name: redcarpet
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '3.4'
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: '3.4'
125
- - !ruby/object:Gem::Dependency
126
- name: rubocop
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: '0.63'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: '0.63'
139
- - !ruby/object:Gem::Dependency
140
- name: yard
141
- requirement: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - "~>"
144
- - !ruby/object:Gem::Version
145
- version: '0.9'
146
- type: :development
147
- prerelease: false
148
- version_requirements: !ruby/object:Gem::Requirement
149
- requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: '0.9'
40
+ version: '2.2'
153
41
  description: A library and CLI tool allowing to decode all 4 types of BigIP cookies
154
42
  email: alexandre.zanni@engineer.com
155
43
  executables:
156
44
  - rabid
157
45
  - rabid_console
158
- - rabid_setup
159
46
  extensions: []
160
47
  extra_rdoc_files: []
161
48
  files:
162
- - ".gitignore"
163
- - ".rubocop.yml"
164
- - ".yardopts"
165
- - ".yardopts-dev"
166
- - Gemfile
167
- - Gemfile.lock
168
49
  - LICENSE.txt
169
- - README.md
170
- - Rakefile
171
50
  - bin/rabid
172
51
  - bin/rabid_console
173
- - bin/rabid_setup
174
- - docs/.nojekyll
175
- - docs/About.md
176
- - docs/CHANGELOG.md
177
- - docs/README.md
178
- - docs/_coverpage.md
179
- - docs/_media/logo.png
180
- - docs/_navbar.md
181
- - docs/_sidebar.md
182
- - docs/index.html
183
- - docs/pages/demo.md
184
- - docs/pages/documentation.md
185
- - docs/pages/install.md
186
- - docs/pages/publishing.md
187
- - docs/pages/quick-start.md
188
- - docs/pages/usage.md
189
- - docs/vendor/docsify.js
190
- - docs/vendor/plugins/emoji.min.js
191
- - docs/vendor/plugins/search.min.js
192
- - docs/vendor/prismjs/components/prism-ruby.min.js
193
- - docs/vendor/themes/vue.css
194
- - docs/why.md
195
- - docs/yard/BigIPCookie.html
196
- - docs/yard/BigIPCookie/Decode.html
197
- - docs/yard/Version.html
198
- - docs/yard/_index.html
199
- - docs/yard/class_list.html
200
- - docs/yard/css/common.css
201
- - docs/yard/css/full_list.css
202
- - docs/yard/css/style.css
203
- - docs/yard/file.LICENSE.html
204
- - docs/yard/file.README.html
205
- - docs/yard/file_list.html
206
- - docs/yard/frames.html
207
- - docs/yard/index.html
208
- - docs/yard/js/app.js
209
- - docs/yard/js/full_list.js
210
- - docs/yard/js/jquery.js
211
- - docs/yard/method_list.html
212
- - docs/yard/top-level-namespace.html
213
52
  - lib/bigipcookie.rb
214
53
  - lib/bigipcookie/version.rb
215
- - package-lock.json
216
- - test/test_bigipcookie.rb
217
- homepage: https://orange-cyberdefense.github.io/rabid/
54
+ homepage: https://noraj.github.io/rabid/
218
55
  licenses:
219
56
  - MIT
220
57
  metadata:
221
58
  yard.run: yard
222
- bug_tracker_uri: https://github.com/Orange-Cyberdefense/rabid/issues
223
- changelog_uri: https://github.com/Orange-Cyberdefense/rabid/blob/master/docs/CHANGELOG.md
224
- documentation_uri: https://orange-cyberdefense.github.io/rabid/
225
- homepage_uri: https://orange-cyberdefense.github.io/rabid/
226
- source_code_uri: https://github.com/Orange-Cyberdefense/rabid/
227
- post_install_message:
59
+ bug_tracker_uri: https://github.com/noraj/rabid/issues
60
+ changelog_uri: https://github.com/noraj/rabid/blob/master/docs/CHANGELOG.md
61
+ documentation_uri: https://noraj.github.io/rabid/
62
+ homepage_uri: https://noraj.github.io/rabid/
63
+ source_code_uri: https://github.com/noraj/rabid/
64
+ rubygems_mfa_required: 'true'
65
+ post_install_message:
228
66
  rdoc_options: []
229
67
  require_paths:
230
68
  - lib
231
69
  required_ruby_version: !ruby/object:Gem::Requirement
232
70
  requirements:
233
- - - "~>"
71
+ - - ">="
72
+ - !ruby/object:Gem::Version
73
+ version: 2.7.0
74
+ - - "<"
234
75
  - !ruby/object:Gem::Version
235
- version: '2.4'
76
+ version: '3.2'
236
77
  required_rubygems_version: !ruby/object:Gem::Requirement
237
78
  requirements:
238
79
  - - ">="
239
80
  - !ruby/object:Gem::Version
240
81
  version: '0'
241
82
  requirements: []
242
- rubygems_version: 3.0.1
243
- signing_key:
83
+ rubygems_version: 3.3.3
84
+ signing_key:
244
85
  specification_version: 4
245
86
  summary: RApid Big IP Decoder
246
- test_files:
247
- - test/test_bigipcookie.rb
87
+ test_files: []
data/.gitignore DELETED
@@ -1,8 +0,0 @@
1
- .yardoc
2
- *.gem
3
- /pkg
4
- /doc
5
- /vendor
6
- .bundle/
7
- /node_modules
8
- .git
data/.rubocop.yml DELETED
@@ -1,22 +0,0 @@
1
- # Metrics
2
- AllCops:
3
- TargetRubyVersion: 2.4
4
-
5
- Layout/AlignHash:
6
- Include:
7
- - 'lib/**/*.rb'
8
- Metrics/AbcSize:
9
- Enabled: false
10
- Metrics/ClassLength:
11
- Max: 200
12
- Metrics/CyclomaticComplexity:
13
- Enabled: false
14
- Metrics/LineLength:
15
- Include:
16
- - 'lib/**/*.rb'
17
- Metrics/MethodLength:
18
- Max: 25
19
- Metrics/PerceivedComplexity:
20
- Max: 10
21
- Style/RedundantReturn:
22
- Enabled: false
data/.yardopts DELETED
@@ -1,4 +0,0 @@
1
- --output-dir docs/yard
2
- -
3
- --main README.md
4
- LICENSE.txt
data/.yardopts-dev DELETED
@@ -1,6 +0,0 @@
1
- --output-dir docs/yard
2
- --protected
3
- --private
4
- -
5
- --main README.md
6
- LICENSE.txt
data/Gemfile DELETED
@@ -1,6 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source 'https://rubygems.org'
4
-
5
- # Specify your gem's dependencies in .gemspec
6
- gemspec
data/Gemfile.lock DELETED
@@ -1,56 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- rabid (0.0.3)
5
- docopt (~> 0.6)
6
- paint (~> 2.1)
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- ast (2.4.0)
12
- commonmarker (0.20.1)
13
- ruby-enum (~> 0.5)
14
- concurrent-ruby (1.1.5)
15
- docopt (0.6.1)
16
- github-markup (3.0.4)
17
- i18n (1.6.0)
18
- concurrent-ruby (~> 1.0)
19
- jaro_winkler (1.5.3)
20
- minitest (5.11.3)
21
- paint (2.1.1)
22
- parallel (1.17.0)
23
- parser (2.6.3.0)
24
- ast (~> 2.4.0)
25
- rainbow (3.0.0)
26
- rake (12.3.2)
27
- redcarpet (3.4.0)
28
- rubocop (0.73.0)
29
- jaro_winkler (~> 1.5.1)
30
- parallel (~> 1.10)
31
- parser (>= 2.6)
32
- rainbow (>= 2.2.2, < 4.0)
33
- ruby-progressbar (~> 1.7)
34
- unicode-display_width (>= 1.4.0, < 1.7)
35
- ruby-enum (0.7.2)
36
- i18n
37
- ruby-progressbar (1.10.1)
38
- unicode-display_width (1.6.0)
39
- yard (0.9.20)
40
-
41
- PLATFORMS
42
- ruby
43
-
44
- DEPENDENCIES
45
- bundler (~> 2.0)
46
- commonmarker (~> 0.20)
47
- github-markup (~> 3.0)
48
- minitest (~> 5.11)
49
- rabid!
50
- rake (~> 12.3)
51
- redcarpet (~> 3.4)
52
- rubocop (~> 0.63)
53
- yard (~> 0.9)
54
-
55
- BUNDLED WITH
56
- 2.0.2
data/README.md DELETED
@@ -1,31 +0,0 @@
1
- # RABID
2
-
3
- [![Gem Version](https://badge.fury.io/rb/rabid.svg)](https://badge.fury.io/rb/rabid)
4
- ![GitHub tag (latest SemVer)](https://img.shields.io/github/tag/Orange-Cyberdefense/rabid)
5
- [![GitHub forks](https://img.shields.io/github/forks/Orange-Cyberdefense/rabid)](https://github.com/Orange-Cyberdefense/rabid/network)
6
- [![GitHub stars](https://img.shields.io/github/stars/Orange-Cyberdefense/rabid)](https://github.com/Orange-Cyberdefense/rabid/stargazers)
7
- [![GitHub license](https://img.shields.io/github/license/Orange-Cyberdefense/rabid)](https://github.com/Orange-Cyberdefense/rabid/blob/master/LICENSE.txt)
8
-
9
- [![Packaging status](https://repology.org/badge/vertical-allrepos/rabid.svg)](https://repology.org/project/rabid/versions)
10
-
11
- ![](https://orange-cyberdefense.github.io/rabid/_media/logo.png)
12
-
13
- > **RA**pid **B**ig **I**P **D**ecoder
14
-
15
- ## What it is
16
-
17
- A CLI tool and library allowing to simply decode all kind of BigIP cookies.
18
-
19
- ## Features
20
-
21
- - Support all 4 cookie formats
22
- - CLI tool & library
23
- - Hackable
24
-
25
- ## References
26
-
27
- Homepage / Documentation: https://orange-cyberdefense.github.io/rabid/
28
-
29
- ## Author
30
-
31
- Made by Alexandre ZANNI ([@noraj](https://github.com/noraj)), pentester from Orange Cyberdefense.
data/Rakefile DELETED
@@ -1,10 +0,0 @@
1
- require 'rake/testtask'
2
- require 'bundler/gem_tasks'
3
-
4
- Rake::TestTask.new do |t|
5
- t.libs << 'test'
6
- end
7
-
8
- desc 'Run tests'
9
- task default: :test
10
-
data/bin/rabid_setup DELETED
@@ -1,6 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -euo pipefail
3
- IFS=$'\n\t'
4
- set -vx
5
-
6
- bundle install
data/docs/.nojekyll DELETED
File without changes
data/docs/About.md DELETED
@@ -1,13 +0,0 @@
1
- # About
2
-
3
- # References
4
-
5
- BigIP cookie decoding is done following the official method provided by F5: https://support.f5.com/csp/article/K6917
6
-
7
- IPv6 URL format try to respect RFC2732: https://tools.ietf.org/html/rfc2732
8
-
9
- Encrypted cookie format is detected from the example given by F5: https://support.f5.com/csp/article/K23254150
10
-
11
- ## Logo
12
-
13
- Logo made with [DesignEvo](https://www.designevo.com).
data/docs/CHANGELOG.md DELETED
@@ -1,13 +0,0 @@
1
- # Changelog
2
-
3
- ## [0.0.3]
4
-
5
- - Update `commonmarker` dependency
6
-
7
- ## [0.0.2]
8
-
9
- - Encrypted cookie detection
10
-
11
- ## [0.0.1]
12
-
13
- - Initial version