ronin-web 2.0.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby.yml +1 -0
  3. data/ChangeLog.md +17 -2
  4. data/README.md +1 -1
  5. data/data/completions/ronin-web +43 -31
  6. data/gemspec.yml +1 -1
  7. data/lib/ronin/web/cli/browser_options.rb +1 -1
  8. data/lib/ronin/web/cli/browser_shell.rb +3 -2
  9. data/lib/ronin/web/cli/command.rb +3 -3
  10. data/lib/ronin/web/cli/commands/browser.rb +5 -5
  11. data/lib/ronin/web/cli/commands/completion.rb +3 -2
  12. data/lib/ronin/web/cli/commands/diff.rb +3 -3
  13. data/lib/ronin/web/cli/commands/html.rb +3 -3
  14. data/lib/ronin/web/cli/commands/irb.rb +3 -3
  15. data/lib/ronin/web/cli/commands/new/app.rb +3 -3
  16. data/lib/ronin/web/cli/commands/new/nokogiri.rb +3 -3
  17. data/lib/ronin/web/cli/commands/new/server.rb +3 -3
  18. data/lib/ronin/web/cli/commands/new/spider.rb +3 -3
  19. data/lib/ronin/web/cli/commands/new.rb +3 -2
  20. data/lib/ronin/web/cli/commands/reverse_proxy.rb +3 -2
  21. data/lib/ronin/web/cli/commands/screenshot.rb +3 -3
  22. data/lib/ronin/web/cli/commands/server.rb +4 -3
  23. data/lib/ronin/web/cli/commands/session_cookie.rb +3 -2
  24. data/lib/ronin/web/cli/commands/spider.rb +4 -3
  25. data/lib/ronin/web/cli/commands/user_agent.rb +3 -2
  26. data/lib/ronin/web/cli/commands/vulns.rb +4 -3
  27. data/lib/ronin/web/cli/commands/wordlist.rb +4 -4
  28. data/lib/ronin/web/cli/commands/xml.rb +3 -3
  29. data/lib/ronin/web/cli/js_shell.rb +1 -1
  30. data/lib/ronin/web/cli/ruby_shell.rb +1 -1
  31. data/lib/ronin/web/cli/spider_options.rb +1 -1
  32. data/lib/ronin/web/cli.rb +3 -2
  33. data/lib/ronin/web/root.rb +1 -1
  34. data/lib/ronin/web/version.rb +2 -2
  35. data/lib/ronin/web.rb +4 -2
  36. data/ronin-web.gemspec +1 -0
  37. metadata +10 -7
  38. data/lib/ronin/web/html.rb +0 -86
  39. data/lib/ronin/web/xml.rb +0 -86
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f60603cab05fa8db75002d8f90142f5ff2e76ea562cf9a85e86e7ee770c5c289
4
- data.tar.gz: 279e4106b0cbd800136f624a51893b264ab3643a3abbfc6869c85593f012d65c
3
+ metadata.gz: c49b1797684e1ac9ca6e158ee6824ff7352804ab9914543824527ba89ab57a98
4
+ data.tar.gz: 443f7a5344f9a16ee8ec1e3904aab4a165be8bcad47eae45a4eb1cddccaa44a3
5
5
  SHA512:
6
- metadata.gz: 128dece960fcb880232c477a16d9a6146b3897a2f7a40f4acdddbdd076599c6c12a0001c5ff37192f99ac226fa18cf2b0d5bad10ee13cbe916e0dbaa715d2bb4
7
- data.tar.gz: 8b0db291154cf808e36585fb0d9d722e020fd918f92d57b9ccd3efad128a5bca29c43a3a61ca4a4ae3b99db131b0a081fc7cbf41877227a4f2c878ac1e12f1d0
6
+ metadata.gz: ff88d3d3e069383c427ebbb874cbc1e2e4abeae71f768958a19f810f33fdcd8ab9a02ba16d9c014e41a6235392313605b86bfe2c87cce8534e3aa0bb56dfa4c6
7
+ data.tar.gz: d113ad11be8cdab75cd68b028e96c5d3fd87eef348fb24b852acea6dcdbe1edbfb947e8afcbcb6e288b23513d6536bf7f3d6352aa761ae6104039a20c964e69e
@@ -13,6 +13,7 @@ jobs:
13
13
  - '3.1'
14
14
  - '3.2'
15
15
  - '3.3'
16
+ - '3.4'
16
17
  # - jruby
17
18
  - truffleruby
18
19
  name: Ruby ${{ matrix.ruby }}
data/ChangeLog.md CHANGED
@@ -1,3 +1,18 @@
1
+ ### 2.0.1 / 2025-02-14
2
+
3
+ * Removed legacy 1.x Ruby files:
4
+ * `ronin/web/html` - This file was moved to [ronin-support-web] and renamed to
5
+ `ronin/support/web/html`.
6
+ * `ronin/web/xml` - This file was moved to [ronin-support-web] and renamed to
7
+ `ronin/support/web/xml`.
8
+ * Require all other `ronin-web-*` libraries in `ronin/web`.
9
+ * Use `require_relative` to improve load times.
10
+
11
+ #### CLI
12
+
13
+ * Fixed a bug in the `ronin-web server` command where the query params of
14
+ requests were not being displayed.
15
+
1
16
  ### 2.0.0 / 2024-07-22
2
17
 
3
18
  * Require [wordlist] ~> 1.0, >= 1.0.1.
@@ -69,8 +84,8 @@
69
84
  * Added the `ronin-web reverse-proxy` command.
70
85
  * Added the `ronin-web server` command.
71
86
  * Added the `ronin-web spider` command.
72
- * Added {Ronin::Web::HTML}.
73
- * Added {Ronin::Web::XML}.
87
+ * Added `Ronin::Web::HTML`.
88
+ * Added `Ronin::Web::XML`.
74
89
 
75
90
  [nokogiri-ext]: https://github.com/postmodern/nokogiri-ext#readme
76
91
  [nokogiri-diff]: https://github.com/postmodern/nokogiri-diff#readme
data/README.md CHANGED
@@ -624,7 +624,7 @@ $ gem install ronin-web
624
624
 
625
625
  ronin-web - A collection of useful web helper methods and commands.
626
626
 
627
- Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
627
+ Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
628
628
 
629
629
  ronin-web is free software: you can redistribute it and/or modify
630
630
  it under the terms of the GNU General Public License as published by
@@ -32,28 +32,28 @@ _ronin-web_completions() {
32
32
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -- "$cur")
33
33
  ;;
34
34
 
35
- 'screenshot'*'--directory')
36
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
37
- ;;
38
-
39
35
  'wordlist'*'--ignore-host')
40
36
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
41
37
  ;;
42
38
 
39
+ 'screenshot'*'--directory')
40
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
41
+ ;;
42
+
43
43
  'wordlist'*'--visit-host')
44
44
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
45
45
  ;;
46
46
 
47
- 'reverse-proxy'*'--host')
48
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
47
+ 'spider'*'--git-archive')
48
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
49
49
  ;;
50
50
 
51
51
  'spider'*'--ignore-host')
52
52
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
53
53
  ;;
54
54
 
55
- 'spider'*'--git-archive')
56
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
55
+ 'reverse-proxy'*'--host')
56
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
57
57
  ;;
58
58
 
59
59
  'spider'*'--visit-host')
@@ -72,20 +72,28 @@ _ronin-web_completions() {
72
72
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -- "$cur")
73
73
  ;;
74
74
 
75
+ 'wordlist'*'--output')
76
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -A directory -- "$cur")
77
+ ;;
78
+
75
79
  'spider'*'--archive')
76
80
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
77
81
  ;;
78
82
 
83
+ 'reverse-proxy'*'-H')
84
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
85
+ ;;
86
+
79
87
  'spider'*'--history')
80
88
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -- "$cur")
81
89
  ;;
82
90
 
83
- 'reverse-proxy'*'-H')
91
+ 'wordlist'*'--host')
84
92
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
85
93
  ;;
86
94
 
87
- 'wordlist'*'--host')
88
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
95
+ 'vulns'*'--db-file')
96
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -A directory -- "$cur")
89
97
  ;;
90
98
 
91
99
  'session_cookie'*)
@@ -116,20 +124,20 @@ _ronin-web_completions() {
116
124
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--host -H --port -p --show-body -b --rewrite-requests --rewrite-responses")" -- "$cur")
117
125
  ;;
118
126
 
119
- 'new nokogiri'*)
120
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -W "$(_ronin-web_completions_filter "--url -U")" -- "$cur")
121
- ;;
122
-
123
127
  'vulns'*'--host')
124
128
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
125
129
  ;;
126
130
 
127
- 'screenshot'*)
128
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --width -W --height -H --file -f --format -F --directory -d --full --css-path -C")" -- "$cur")
131
+ 'new nokogiri'*)
132
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -W "$(_ronin-web_completions_filter "--url -U")" -- "$cur")
129
133
  ;;
130
134
 
131
- 'new spider'*)
132
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -W "$(_ronin-web_completions_filter "--host --domain --site --every-link --every-url --every-failed-url --every-url-like --all-headers --every-page --every-ok-page --every-redirect-page --every-timedout-page --every-bad-request-page --every-unauthorized-page --every-forbidden-page --every-missing-page --every-internal-server-error-page --every-txt-page --every-html-page --every-xml-page --every-xsl-page --every-javascript-page --every-css-page --every-rss-page --every-atom-page --every-ms-word-page --every-pdf-page --every-zip-page --every-doc --every-html-doc --every-xml-doc --every-xsl-doc --every-rss-doc --every-atom-doc")" -- "$cur")
135
+ 'wordlist'*'-o')
136
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -A directory -- "$cur")
137
+ ;;
138
+
139
+ 'user_agent'*)
140
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --chrome-version --firefox-version --linux-distro -D --arch -A --os -O --os-version")" -- "$cur")
133
141
  ;;
134
142
 
135
143
  'new server'*)
@@ -140,30 +148,34 @@ _ronin-web_completions() {
140
148
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--print --install --uninstall")" -- "$cur")
141
149
  ;;
142
150
 
143
- 'user_agent'*)
144
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --chrome-version --firefox-version --linux-distro -D --arch -A --os -O --os-version")" -- "$cur")
151
+ 'screenshot'*)
152
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --width -W --height -H --file -f --format -F --directory -d --full --css-path -C")" -- "$cur")
145
153
  ;;
146
154
 
147
- 'server'*'-H')
148
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
155
+ 'new spider'*)
156
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A file -W "$(_ronin-web_completions_filter "--host --domain --site --every-link --every-url --every-failed-url --every-url-like --all-headers --every-page --every-ok-page --every-redirect-page --every-timedout-page --every-bad-request-page --every-unauthorized-page --every-forbidden-page --every-missing-page --every-internal-server-error-page --every-txt-page --every-html-page --every-xml-page --every-xsl-page --every-javascript-page --every-css-page --every-rss-page --every-atom-page --every-ms-word-page --every-pdf-page --every-zip-page --every-doc --every-html-doc --every-xml-doc --every-xsl-doc --every-rss-doc --every-atom-doc")" -- "$cur")
149
157
  ;;
150
158
 
151
159
  'server'*'-r')
152
160
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -- "$cur")
153
161
  ;;
154
162
 
155
- 'wordlist'*)
156
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--host --domain --site --open-timeout --read-timeout --ssl-timeout --continue-timeout --keep-alive-timeout --proxy -P --header -H --host-header --user-agent-string -U --user-agent -u --referer -R --delay -d --limit -l --max-depth -d --enqueue --visited --strip-fragments --strip-query --visit-scheme --visit-schemes-like --ignore-scheme --ignore-schemes-like --visit-host --visit-hosts-like --ignore-host --ignore-hosts-like --visit-port --visit-ports-like --ignore-port --ignore-ports-like --visit-link --visit-links-like --ignore-link --ignore-links-like --visit-ext --visit-exts-like --ignore-ext --ignore-exts-like --robots -r --output -o --content-xpath -X --content-css-path -C --meta-tags --no-meta-tags --comments --no-comments --alt-tags --no-alt-tags --paths --query-params-names --query-param-values --only-paths --only-query-param --only-query-param-values --format -f --append -A --lang -L --stop-word --ignore-word --digits --no-digits --special-char --numbers --no-numbers --acronyms --no-acronyms --normalize-case --no-normalize-case --normalize-apostrophes --no-normalize-apostrophes --normalize-acronyms --no-normalize-acronyms")" -- "$cur")
163
+ 'server'*'-H')
164
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A hostname -- "$cur")
157
165
  ;;
158
166
 
159
- 'browser'*)
160
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --width -W --height -H --headless --visible --x -x --y -y --inject-js --inject-js-file --bypass-csp --print-urls --print-status --print-requests --print-responses --print-traffic --print-headers --print-cookies --print-body --shell --js-shell")" -- "$cur")
167
+ 'wordlist'*)
168
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--host --domain --site --open-timeout --read-timeout --ssl-timeout --continue-timeout --keep-alive-timeout --proxy -P --header -H --host-header --user-agent-string -U --user-agent -u --referer -R --delay -d --limit -l --max-depth -d --enqueue --visited --strip-fragments --strip-query --visit-scheme --visit-schemes-like --ignore-scheme --ignore-schemes-like --visit-host --visit-hosts-like --ignore-host --ignore-hosts-like --visit-port --visit-ports-like --ignore-port --ignore-ports-like --visit-link --visit-links-like --ignore-link --ignore-links-like --visit-ext --visit-exts-like --ignore-ext --ignore-exts-like --robots -r --output -o --content-xpath -X --content-css-path -C --meta-tags --no-meta-tags --comments --no-comments --alt-tags --no-alt-tags --paths --query-params-names --query-param-values --only-paths --only-query-param --only-query-param-values --format -f --append -A --lang -L --stop-word --ignore-word --digits --no-digits --special-char --numbers --no-numbers --acronyms --no-acronyms --normalize-case --no-normalize-case --normalize-apostrophes --no-normalize-apostrophes --normalize-acronyms --no-normalize-acronyms")" -- "$cur")
161
169
  ;;
162
170
 
163
171
  'new app'*)
164
172
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -W "$(_ronin-web_completions_filter "--port --ruby-version --git --dockerfile -D")" -- "$cur")
165
173
  ;;
166
174
 
175
+ 'browser'*)
176
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--browser -B --width -W --height -H --headless --visible --x -x --y -y --inject-js --inject-js-file --bypass-csp --print-urls --print-status --print-requests --print-responses --print-traffic --print-headers --print-cookies --print-body --shell --js-shell")" -- "$cur")
177
+ ;;
178
+
167
179
  'spider'*)
168
180
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--host --domain --site --open-timeout --read-timeout --ssl-timeout --continue-timeout --keep-alive-timeout --proxy -P --header -H --host-header --user-agent-string -U --user-agent -u --referer -R --delay -d --limit -l --max-depth -d --enqueue --visited --strip-fragments --strip-query --visit-scheme --visit-schemes-like --ignore-scheme --ignore-schemes-like --visit-host --visit-hosts-like --ignore-host --ignore-hosts-like --visit-port --visit-ports-like --ignore-port --ignore-ports-like --visit-link --visit-links-like --ignore-link --ignore-links-like --visit-ext --visit-exts-like --ignore-ext --ignore-exts-like --robots -r --verbose -v --print-stauts --print-headers --print-header --history --archive --git-archive --xpath -X --css-path -C --print-hosts --print-certs --save-certs --print-js-strings --print-js-url-strings --print-js-path-strings --print-js-absolute-path-strings --print-js-relative-path-strings --print-html-comments --print-js-comments --print-comments")" -- "$cur")
169
181
  ;;
@@ -176,14 +188,14 @@ _ronin-web_completions() {
176
188
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--host --domain --site --open-timeout --read-timeout --ssl-timeout --continue-timeout --keep-alive-timeout --proxy -P --header -H --host-header --user-agent-string -U --user-agent -u --referer -R --delay -d --limit -l --max-depth -d --enqueue --visited --strip-fragments --strip-query --visit-scheme --visit-schemes-like --ignore-scheme --ignore-schemes-like --visit-host --visit-hosts-like --ignore-host --ignore-hosts-like --visit-port --visit-ports-like --ignore-port --ignore-ports-like --visit-link --visit-links-like --ignore-link --ignore-links-like --visit-ext --visit-exts-like --ignore-ext --ignore-exts-like --robots -r --db --db-uri --db-file --first -F --all -A --print-curl --print-http --import --lfi-os --lfi-depth --lfi-filter-bypass --rfi-filter-bypass --rfi-script-lang --rfi-test-script-url --sqli-escape-quote --sqli-escape-parens --sqli-terminate --ssti-test-expr --open-redirect-url")" -- "$cur")
177
189
  ;;
178
190
 
179
- 'diff'*)
180
- while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--format -f")" -- "$cur")
181
- ;;
182
-
183
191
  'html'*)
184
192
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--xpath -X --first -F --text -t --css-path -C --meta-tags -M --links -l --style -S --stylesheet-urls -s --javascript -J --javascript-urls -j --form-urls -f --urls -u")" -- "$cur")
185
193
  ;;
186
194
 
195
+ 'diff'*)
196
+ while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--format -f")" -- "$cur")
197
+ ;;
198
+
187
199
  'xml'*)
188
200
  while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_ronin-web_completions_filter "--xpath -X --first -F --text -t")" -- "$cur")
189
201
  ;;
data/gemspec.yml CHANGED
@@ -4,7 +4,7 @@ description:
4
4
  ronin-web is a Ruby library that provides common web security commands and
5
5
  additional libraries.
6
6
 
7
- license: GPL-3.0
7
+ license: GPL-3.0-or-later
8
8
  authors: Postmodern
9
9
  email: postmodern.mod3@gmail.com
10
10
  homepage: https://github.com/ronin-rb/ronin-web#readme
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -19,9 +19,10 @@
19
19
  #
20
20
 
21
21
  require 'ronin/core/cli/command_shell'
22
- require 'ronin/web/cli/js_shell'
23
22
  require 'ronin/web/browser'
24
23
 
24
+ require_relative 'js_shell'
25
+
25
26
  module Ronin
26
27
  module Web
27
28
  class CLI
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,10 +18,10 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/root'
22
-
23
21
  require 'ronin/core/cli/command'
24
22
 
23
+ require_relative '../root'
24
+
25
25
  module Ronin
26
26
  module Web
27
27
  class CLI
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,10 +18,10 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/browser_options'
23
- require 'ronin/web/cli/browser_shell'
24
- require 'ronin/web/cli/js_shell'
21
+ require_relative '../command'
22
+ require_relative '../browser_options'
23
+ require_relative '../browser_shell'
24
+ require_relative '../js_shell'
25
25
 
26
26
  require 'command_kit/colors'
27
27
 
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,9 +18,10 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/root'
22
21
  require 'ronin/core/cli/completion_command'
23
22
 
23
+ require_relative '../../root'
24
+
24
25
  module Ronin
25
26
  module Web
26
27
  class CLI
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,9 +18,9 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/support/network/http'
21
+ require_relative '../command'
23
22
 
23
+ require 'ronin/support/network/http'
24
24
  require 'command_kit/colors'
25
25
  require 'nokogiri/diff'
26
26
 
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,9 +18,9 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/commands/xml'
22
- require 'ronin/support/network/http'
21
+ require_relative 'xml'
23
22
 
23
+ require 'ronin/support/network/http'
24
24
  require 'nokogiri'
25
25
 
26
26
  module Ronin
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,8 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/ruby_shell'
21
+ require_relative '../command'
22
+ require_relative '../ruby_shell'
23
23
 
24
24
  module Ronin
25
25
  module Web
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
  #
3
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
3
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
4
4
  #
5
5
  # ronin-web is free software: you can redistribute it and/or modify
6
6
  # it under the terms of the GNU General Public License as published by
@@ -16,8 +16,8 @@
16
16
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
17
17
  #
18
18
 
19
- require 'ronin/web/cli/command'
20
- require 'ronin/web/root'
19
+ require_relative '../../command'
20
+ require_relative '../../../root'
21
21
 
22
22
  require 'ronin/core/cli/generator'
23
23
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
  #
3
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
3
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
4
4
  #
5
5
  # ronin-web is free software: you can redistribute it and/or modify
6
6
  # it under the terms of the GNU General Public License as published by
@@ -16,8 +16,8 @@
16
16
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
17
17
  #
18
18
 
19
- require 'ronin/web/cli/command'
20
- require 'ronin/web/root'
19
+ require_relative '../../command'
20
+ require_relative '../../../root'
21
21
 
22
22
  require 'ronin/core/cli/generator'
23
23
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
  #
3
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
3
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
4
4
  #
5
5
  # ronin-web is free software: you can redistribute it and/or modify
6
6
  # it under the terms of the GNU General Public License as published by
@@ -16,8 +16,8 @@
16
16
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
17
17
  #
18
18
 
19
- require 'ronin/web/cli/command'
20
- require 'ronin/web/root'
19
+ require_relative '../../command'
20
+ require_relative '../../../root'
21
21
 
22
22
  require 'ronin/core/cli/generator'
23
23
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
  #
3
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
3
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
4
4
  #
5
5
  # ronin-web is free software: you can redistribute it and/or modify
6
6
  # it under the terms of the GNU General Public License as published by
@@ -16,8 +16,8 @@
16
16
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
17
17
  #
18
18
 
19
- require 'ronin/web/cli/command'
20
- require 'ronin/web/root'
19
+ require_relative '../../command'
20
+ require_relative '../../../root'
21
21
 
22
22
  require 'ronin/core/cli/generator'
23
23
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
  #
3
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
3
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
4
4
  #
5
5
  # ronin-web is free software: you can redistribute it and/or modify
6
6
  # it under the terms of the GNU General Public License as published by
@@ -16,7 +16,8 @@
16
16
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
17
17
  #
18
18
 
19
- require 'ronin/web/cli/command'
19
+ require_relative '../command'
20
+
20
21
  require 'command_kit/commands/auto_load'
21
22
 
22
23
  module Ronin
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,7 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
21
+ require_relative '../command'
22
+
22
23
  require 'ronin/core/cli/logging'
23
24
  require 'ronin/web/server/reverse_proxy'
24
25
 
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,8 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/browser_options'
21
+ require_relative '../command'
22
+ require_relative '../browser_options'
23
23
 
24
24
  require 'ronin/core/cli/logging'
25
25
 
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,7 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
21
+ require_relative '../command'
22
+
22
23
  require 'ronin/core/cli/logging'
23
24
  require 'ronin/web/server'
24
25
 
@@ -134,7 +135,7 @@ module Ronin
134
135
  App.public_dir = options[:root]
135
136
  else
136
137
  App.any('*') do
137
- puts "#{request.request_method} #{request.path}"
138
+ puts "#{request.request_method} #{request.fullpath}"
138
139
 
139
140
  request.headers.each do |name,value|
140
141
  puts "#{name}: #{value}"
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,7 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
21
+ require_relative '../command'
22
+
22
23
  require 'ronin/web/session_cookie'
23
24
  require 'ronin/support/network/http'
24
25
  require 'ronin/support/encoding/hex'
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,8 +18,9 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/spider_options'
21
+ require_relative '../command'
22
+ require_relative '../spider_options'
23
+
23
24
  require 'ronin/web/spider/archive'
24
25
  require 'ronin/web/spider/git_archive'
25
26
  require 'ronin/support/network/http/user_agents'
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,7 +18,8 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
21
+ require_relative '../command'
22
+
22
23
  require 'ronin/web/user_agents'
23
24
 
24
25
  module Ronin
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,8 +18,9 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/spider_options'
21
+ require_relative '../command'
22
+ require_relative '../spider_options'
23
+
23
24
  require 'ronin/core/cli/logging'
24
25
  require 'ronin/vulns/url_scanner'
25
26
  require 'ronin/vulns/cli/printing'
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,10 +18,10 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/web/cli/spider_options'
23
- require 'ronin/core/cli/logging'
21
+ require_relative '../command'
22
+ require_relative '../spider_options'
24
23
 
24
+ require 'ronin/core/cli/logging'
25
25
  require 'wordlist/builder'
26
26
  require 'nokogiri'
27
27
 
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,9 +18,9 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/cli/command'
22
- require 'ronin/support/network/http'
21
+ require_relative '../command'
23
22
 
23
+ require 'ronin/support/network/http'
24
24
  require 'nokogiri'
25
25
 
26
26
  module Ronin
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
data/lib/ronin/web/cli.rb CHANGED
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -18,13 +18,14 @@
18
18
  # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
19
  #
20
20
 
21
- require 'ronin/web/version'
22
21
  require 'ronin/core/cli/help/banner'
23
22
 
24
23
  require 'command_kit/commands'
25
24
  require 'command_kit/commands/auto_load'
26
25
  require 'command_kit/options/version'
27
26
 
27
+ require_relative 'version'
28
+
28
29
  module Ronin
29
30
  module Web
30
31
  #
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -21,6 +21,6 @@
21
21
  module Ronin
22
22
  module Web
23
23
  # ronin-web Version
24
- VERSION = '2.0.0'
24
+ VERSION = '2.0.1'
25
25
  end
26
26
  end
data/lib/ronin/web.rb CHANGED
@@ -2,7 +2,7 @@
2
2
  #
3
3
  # ronin-web - A collection of useful web helper methods and commands.
4
4
  #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
5
+ # Copyright (c) 2006-2025 Hal Brodigan (postmodern.mod3 at gmail.com)
6
6
  #
7
7
  # ronin-web is free software: you can redistribute it and/or modify
8
8
  # it under the terms of the GNU General Public License as published by
@@ -19,8 +19,10 @@
19
19
  #
20
20
 
21
21
  require 'ronin/support/web'
22
- require 'ronin/web/spider'
22
+ require 'ronin/web/browser'
23
23
  require 'ronin/web/server'
24
+ require 'ronin/web/session_cookie'
25
+ require 'ronin/web/spider'
24
26
  require 'ronin/web/user_agents'
25
27
  require 'ronin/web/version'
26
28
 
data/ronin-web.gemspec CHANGED
@@ -20,6 +20,7 @@ Gem::Specification.new do |gem|
20
20
  gem.authors = Array(gemspec['authors'])
21
21
  gem.email = gemspec['email']
22
22
  gem.homepage = gemspec['homepage']
23
+ gem.metadata = gemspec['metadata'] if gemspec['metadata']
23
24
 
24
25
  glob = ->(patterns) { gem.files & Dir[*patterns] }
25
26
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ronin-web
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Postmodern
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-07-22 00:00:00.000000000 Z
11
+ date: 2025-02-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri
@@ -297,10 +297,8 @@ files:
297
297
  - lib/ronin/web/cli/js_shell.rb
298
298
  - lib/ronin/web/cli/ruby_shell.rb
299
299
  - lib/ronin/web/cli/spider_options.rb
300
- - lib/ronin/web/html.rb
301
300
  - lib/ronin/web/root.rb
302
301
  - lib/ronin/web/version.rb
303
- - lib/ronin/web/xml.rb
304
302
  - man/ronin-web-browser.1
305
303
  - man/ronin-web-browser.1.md
306
304
  - man/ronin-web-completion.1
@@ -345,8 +343,13 @@ files:
345
343
  - scripts/setup
346
344
  homepage: https://github.com/ronin-rb/ronin-web#readme
347
345
  licenses:
348
- - GPL-3.0
349
- metadata: {}
346
+ - GPL-3.0-or-later
347
+ metadata:
348
+ documentation_uri: https://ronin-rb.dev/docs/ronin-web
349
+ source_code_uri: https://github.com/ronin-rb/ronin-web
350
+ bug_tracker_uri: https://github.com/ronin-rb/ronin-web/issues
351
+ changelog_uri: https://github.com/ronin-rb/ronin-web/blob/main/ChangeLog.md
352
+ rubygems_mfa_required: 'true'
350
353
  post_install_message:
351
354
  rdoc_options: []
352
355
  require_paths:
@@ -362,7 +365,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
362
365
  - !ruby/object:Gem::Version
363
366
  version: '0'
364
367
  requirements: []
365
- rubygems_version: 3.5.11
368
+ rubygems_version: 3.5.22
366
369
  signing_key:
367
370
  specification_version: 4
368
371
  summary: A collection of common web security commands and libraries.
@@ -1,86 +0,0 @@
1
- # frozen_string_literal: true
2
- #
3
- # ronin-web - A collection of useful web helper methods and commands.
4
- #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
6
- #
7
- # ronin-web is free software: you can redistribute it and/or modify
8
- # it under the terms of the GNU General Public License as published by
9
- # the Free Software Foundation, either version 3 of the License, or
10
- # (at your option) any later version.
11
- #
12
- # ronin-web is distributed in the hope that it will be useful,
13
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
14
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
- # GNU General Public License for more details.
16
- #
17
- # You should have received a copy of the GNU General Public License
18
- # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
- #
20
-
21
- require 'nokogiri'
22
-
23
- module Ronin
24
- module Web
25
- #
26
- # HTML helper methods.
27
- #
28
- # @since 1.0.0
29
- #
30
- module HTML
31
- #
32
- # Parses the body of a document into a HTML document object.
33
- #
34
- # @param [String, IO] html
35
- # The HTML to parse.
36
- #
37
- # @yield [doc]
38
- # If a block is given, it will be passed the newly created document
39
- # object.
40
- #
41
- # @yieldparam [Nokogiri::HTML::Document] doc
42
- # The new HTML document object.
43
- #
44
- # @return [Nokogiri::HTML::Document]
45
- # The new HTML document object.
46
- #
47
- # @see http://rubydoc.info/gems/nokogiri/Nokogiri/HTML/Document
48
- #
49
- # @api public
50
- #
51
- def self.parse(html)
52
- doc = Nokogiri::HTML.parse(html)
53
- yield doc if block_given?
54
- return doc
55
- end
56
-
57
- #
58
- # Creates a new `Nokogiri::HTML::Builder`.
59
- #
60
- # @yield []
61
- # The block that will be used to construct the HTML document.
62
- #
63
- # @return [Nokogiri::HTML::Builder]
64
- # The new HTML builder object.
65
- #
66
- # @example
67
- # HTML.build do
68
- # html {
69
- # body {
70
- # div(style: 'display:none;') {
71
- # object(classid: 'blabla')
72
- # }
73
- # }
74
- # }
75
- # end
76
- #
77
- # @see http://rubydoc.info/gems/nokogiri/Nokogiri/HTML/Builder
78
- #
79
- # @api public
80
- #
81
- def self.build(&block)
82
- Nokogiri::HTML::Builder.new(&block)
83
- end
84
- end
85
- end
86
- end
data/lib/ronin/web/xml.rb DELETED
@@ -1,86 +0,0 @@
1
- # frozen_string_literal: true
2
- #
3
- # ronin-web - A collection of useful web helper methods and commands.
4
- #
5
- # Copyright (c) 2006-2024 Hal Brodigan (postmodern.mod3 at gmail.com)
6
- #
7
- # ronin-web is free software: you can redistribute it and/or modify
8
- # it under the terms of the GNU General Public License as published by
9
- # the Free Software Foundation, either version 3 of the License, or
10
- # (at your option) any later version.
11
- #
12
- # ronin-web is distributed in the hope that it will be useful,
13
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
14
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
- # GNU General Public License for more details.
16
- #
17
- # You should have received a copy of the GNU General Public License
18
- # along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
19
- #
20
-
21
- require 'nokogiri'
22
-
23
- module Ronin
24
- module Web
25
- #
26
- # XML helper methods.
27
- #
28
- # @since 1.0.0
29
- #
30
- module XML
31
- #
32
- # Parses the body of a document into a HTML document object.
33
- #
34
- # @param [String, IO] xml
35
- # The XML to parse.
36
- #
37
- # @yield [doc]
38
- # If a block is given, it will be passed the newly created document
39
- # object.
40
- #
41
- # @yieldparam [Nokogiri::XML::Document] doc
42
- # The new XML document object.
43
- #
44
- # @return [Nokogiri::XML::Document]
45
- # The new HTML document object.
46
- #
47
- # @see http://rubydoc.info/gems/nokogiri/Nokogiri/XML/Document
48
- #
49
- # @api public
50
- #
51
- def self.parse(xml)
52
- doc = Nokogiri::XML.parse(xml)
53
- yield doc if block_given?
54
- return doc
55
- end
56
-
57
- #
58
- # Creates a new `Nokogiri::XML::Builder`.
59
- #
60
- # @yield []
61
- # The block that will be used to construct the XML document.
62
- #
63
- # @return [Nokogiri::XML::Builder]
64
- # The new XML builder object.
65
- #
66
- # @example
67
- # HTML.build do
68
- # html {
69
- # body {
70
- # div(style: 'display:none;') {
71
- # object(classid: 'blabla')
72
- # }
73
- # }
74
- # }
75
- # end
76
- #
77
- # @see http://rubydoc.info/gems/nokogiri/Nokogiri/XML/Builder
78
- #
79
- # @api public
80
- #
81
- def self.build(&block)
82
- Nokogiri::XML::Builder.new(&block)
83
- end
84
- end
85
- end
86
- end