ronin-web 1.0.0.beta1 → 1.0.0.beta2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +5 -4
- data/data/new/nokogiri.rb.erb +1 -1
- data/data/new/spider.rb.erb +1 -1
- data/gemspec.yml +11 -7
- data/lib/ronin/web/cli/command.rb +1 -1
- data/lib/ronin/web/cli/commands/diff.rb +1 -1
- data/lib/ronin/web/cli/commands/html.rb +1 -1
- data/lib/ronin/web/cli/commands/irb.rb +1 -1
- data/lib/ronin/web/cli/commands/new/nokogiri.rb +1 -1
- data/lib/ronin/web/cli/commands/new/server.rb +1 -1
- data/lib/ronin/web/cli/commands/new/spider.rb +1 -1
- data/lib/ronin/web/cli/commands/new/webapp.rb +1 -1
- data/lib/ronin/web/cli/commands/new.rb +1 -1
- data/lib/ronin/web/cli/commands/reverse_proxy.rb +1 -1
- data/lib/ronin/web/cli/commands/server.rb +1 -1
- data/lib/ronin/web/cli/commands/spider.rb +1 -1
- data/lib/ronin/web/cli/ruby_shell.rb +1 -1
- data/lib/ronin/web/cli.rb +6 -1
- data/lib/ronin/web/html.rb +1 -1
- data/lib/ronin/web/mechanize.rb +1 -1
- data/lib/ronin/web/root.rb +1 -1
- data/lib/ronin/web/version.rb +2 -2
- data/lib/ronin/web/xml.rb +1 -1
- data/lib/ronin/web.rb +8 -8
- data/spec/web_spec.rb +6 -6
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 67b858bfc218967ff56b0f90ccc1a3abc78c707cd160c3b2800731882df26066
|
4
|
+
data.tar.gz: 533b6cbdbd94ad449e404985b649f07903ae62f560d5887173dfafc8d9f6cad4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e276c68bc6f0b6d7c6e7f8c267d08c16d92eb7dfd386a52537d7da8c87c74ad0a7ca5586ba522adca971a8269c20adea43ee7ae962c1cd09b5f90883a8f67842
|
7
|
+
data.tar.gz: bb3b259a383a2ce62b91fef94bb70493a267ede5dd24c26970ffaf9bb3b303fdeaafd376e90fecbbe0dff721d12dba69afcb1f2b019cae2f483f177cd23d6e7d
|
data/README.md
CHANGED
@@ -12,8 +12,8 @@
|
|
12
12
|
|
13
13
|
## Description
|
14
14
|
|
15
|
-
ronin-web is a
|
16
|
-
|
15
|
+
ronin-web is a Ruby library that provides common web security commands and
|
16
|
+
additional libraries.
|
17
17
|
|
18
18
|
ronin-web is part of the [ronin-rb] project, a [Ruby] toolkit for security
|
19
19
|
research and development.
|
@@ -26,7 +26,7 @@ research and development.
|
|
26
26
|
* Supports diffing HTML/XML documents using [nokogiri-diff].
|
27
27
|
* Automated Web Browsing using [Mechanize][mechanize].
|
28
28
|
* Supports random `User-Agent` generation using [ronin-web-user_agents].
|
29
|
-
* Provides an easy to use [Sinatra][
|
29
|
+
* Provides an easy to use [Sinatra][sinatra] based web server using
|
30
30
|
[ronin-web-server].
|
31
31
|
* Provides an easy to use web spider using [ronin-web-spider].
|
32
32
|
* Provides a CLI for common web related tasks.
|
@@ -180,7 +180,7 @@ $ gem install ronin-web
|
|
180
180
|
|
181
181
|
ronin-web - A collection of useful web helper methods and commands.
|
182
182
|
|
183
|
-
Copyright (c) 2006-
|
183
|
+
Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
184
184
|
|
185
185
|
ronin-web is free software: you can redistribute it and/or modify
|
186
186
|
it under the terms of the GNU General Public License as published by
|
@@ -211,3 +211,4 @@ along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
|
|
211
211
|
[ronin-web-spider]: https://github.com/ronin-rb/ronin-web-spider#readme
|
212
212
|
[ronin-web-user_agents]: https://github.com/ronin-rb/ronin-web-user_agents#readme
|
213
213
|
[ronin]: https://github.com/ronin-rb/ronin#readme
|
214
|
+
[sinatra]: https://sinatrarb.com/
|
data/data/new/nokogiri.rb.erb
CHANGED
data/data/new/spider.rb.erb
CHANGED
data/gemspec.yml
CHANGED
@@ -1,11 +1,8 @@
|
|
1
1
|
name: ronin-web
|
2
|
-
summary:
|
3
|
-
A Ruby library that provides support for web scraping and
|
4
|
-
spidering functionality.
|
5
|
-
|
2
|
+
summary: A collection of common web security commands and libraries.
|
6
3
|
description:
|
7
|
-
ronin-web is a Ruby library that provides
|
8
|
-
|
4
|
+
ronin-web is a Ruby library that provides common web security commands and
|
5
|
+
additional libraries.
|
9
6
|
|
10
7
|
license: GPL-3.0
|
11
8
|
authors: Postmodern
|
@@ -15,6 +12,13 @@ has_yard: true
|
|
15
12
|
|
16
13
|
required_ruby_version: ">= 3.0.0"
|
17
14
|
|
15
|
+
metadata:
|
16
|
+
documentation_uri: https://ronin-rb.dev/docs/ronin-web
|
17
|
+
source_code_uri: https://github.com/ronin-rb/ronin-web
|
18
|
+
bug_tracker_uri: https://github.com/ronin-rb/ronin-web/issues
|
19
|
+
changelog_uri: https://github.com/ronin-rb/ronin-web/blob/main/ChangeLog.md
|
20
|
+
rubygems_mfa_required: 'true'
|
21
|
+
|
18
22
|
generated_files:
|
19
23
|
- man/ronin-web.1
|
20
24
|
- man/ronin-web-diff.1
|
@@ -36,7 +40,7 @@ dependencies:
|
|
36
40
|
mechanize: ~> 2.0
|
37
41
|
open_namespace: ~> 0.4
|
38
42
|
# Ronin dependencies:
|
39
|
-
ronin-support: ~> 1.0.0.
|
43
|
+
ronin-support: ~> 1.0.0.beta2
|
40
44
|
ronin-web-server: ~> 0.1.0.beta1
|
41
45
|
ronin-web-spider: ~> 0.1.0.beta2
|
42
46
|
ronin-web-user_agents: ~> 0.1.0.beta1
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
#
|
3
|
-
# Copyright (c) 2006-
|
3
|
+
# Copyright (c) 2006-2023 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
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
#
|
3
|
-
# Copyright (c) 2006-
|
3
|
+
# Copyright (c) 2006-2023 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
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
#
|
3
|
-
# Copyright (c) 2006-
|
3
|
+
# Copyright (c) 2006-2023 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
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
#
|
3
|
-
# Copyright (c) 2006-
|
3
|
+
# Copyright (c) 2006-2023 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
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
#
|
3
|
-
# Copyright (c) 2006-
|
3
|
+
# Copyright (c) 2006-2023 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
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
data/lib/ronin/web/cli.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -17,8 +17,11 @@
|
|
17
17
|
# along with ronin-web. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
|
+
require 'ronin/web/version'
|
21
|
+
|
20
22
|
require 'command_kit/commands'
|
21
23
|
require 'command_kit/commands/auto_load'
|
24
|
+
require 'command_kit/options/version'
|
22
25
|
|
23
26
|
module Ronin
|
24
27
|
module Web
|
@@ -36,8 +39,10 @@ module Ronin
|
|
36
39
|
dir: "#{__dir__}/cli/commands",
|
37
40
|
namespace: "#{self}::Commands"
|
38
41
|
)
|
42
|
+
include CommandKit::Options::Version
|
39
43
|
|
40
44
|
command_name 'ronin-web'
|
45
|
+
version Ronin::Web::VERSION
|
41
46
|
|
42
47
|
end
|
43
48
|
end
|
data/lib/ronin/web/html.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
data/lib/ronin/web/mechanize.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
data/lib/ronin/web/root.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
data/lib/ronin/web/version.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -20,6 +20,6 @@
|
|
20
20
|
module Ronin
|
21
21
|
module Web
|
22
22
|
# ronin-web Version
|
23
|
-
VERSION = '1.0.0.
|
23
|
+
VERSION = '1.0.0.beta2'
|
24
24
|
end
|
25
25
|
end
|
data/lib/ronin/web/xml.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
data/lib/ronin/web.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
#
|
2
2
|
# ronin-web - A collection of useful web helper methods and commands.
|
3
3
|
#
|
4
|
-
# Copyright (c) 2006-
|
4
|
+
# Copyright (c) 2006-2023 Hal Brodigan (postmodern.mod3 at gmail.com)
|
5
5
|
#
|
6
6
|
# ronin-web is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU General Public License as published by
|
@@ -195,15 +195,15 @@ module Ronin
|
|
195
195
|
#
|
196
196
|
# @api public
|
197
197
|
#
|
198
|
-
def self.open(url, proxy:
|
199
|
-
user_agent:
|
198
|
+
def self.open(url, proxy: Support::Network::HTTP.proxy,
|
199
|
+
user_agent: Support::Network::HTTP.user_agent,
|
200
200
|
referer: nil,
|
201
201
|
cookie: nil,
|
202
202
|
**kwargs)
|
203
|
-
|
203
|
+
options = {proxy: proxy, **kwargs}
|
204
204
|
|
205
205
|
if user_agent
|
206
|
-
|
206
|
+
options['User-Agent'] = case user_agent
|
207
207
|
when Symbol
|
208
208
|
Support::Network::HTTP::UserAgents[user_agent]
|
209
209
|
else
|
@@ -211,10 +211,10 @@ module Ronin
|
|
211
211
|
end
|
212
212
|
end
|
213
213
|
|
214
|
-
|
215
|
-
|
214
|
+
options['Referer'] = referer if referer
|
215
|
+
options['Cookie'] = cookie if cookie
|
216
216
|
|
217
|
-
return URI.open(url,
|
217
|
+
return URI.open(url,options)
|
218
218
|
end
|
219
219
|
|
220
220
|
#
|
data/spec/web_spec.rb
CHANGED
@@ -2,8 +2,7 @@ require 'spec_helper'
|
|
2
2
|
require 'ronin/web'
|
3
3
|
|
4
4
|
describe Ronin::Web do
|
5
|
-
|
6
|
-
let(:title) { 'Ronin' }
|
5
|
+
let(:url) { 'https://example.com/' }
|
7
6
|
|
8
7
|
it "should have a VERSION constant" do
|
9
8
|
expect(subject.const_defined?('VERSION')).to eq(true)
|
@@ -61,10 +60,11 @@ describe Ronin::Web do
|
|
61
60
|
end
|
62
61
|
|
63
62
|
describe ".open", :network do
|
64
|
-
it "
|
63
|
+
it "must open URLs as temporary files" do
|
65
64
|
file = subject.open(url)
|
66
65
|
|
67
|
-
expect(file
|
66
|
+
expect(file).to be_kind_of(StringIO)
|
67
|
+
expect(file.read).to include("Example Domain")
|
68
68
|
end
|
69
69
|
end
|
70
70
|
|
@@ -83,7 +83,7 @@ describe Ronin::Web do
|
|
83
83
|
page = subject.get(url)
|
84
84
|
|
85
85
|
expect(page.class).to eq(Mechanize::Page)
|
86
|
-
expect(page.
|
86
|
+
expect(page.uri).to eq(URI(url))
|
87
87
|
end
|
88
88
|
end
|
89
89
|
|
@@ -91,7 +91,7 @@ describe Ronin::Web do
|
|
91
91
|
it "should be able to get the bodies of Mechanize pages" do
|
92
92
|
body = subject.get_body(url)
|
93
93
|
|
94
|
-
expect(body).to include(
|
94
|
+
expect(body).to include("Example Domain")
|
95
95
|
end
|
96
96
|
end
|
97
97
|
end
|
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: 1.0.0.
|
4
|
+
version: 1.0.0.beta2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Postmodern
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-01-
|
11
|
+
date: 2023-01-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -86,14 +86,14 @@ dependencies:
|
|
86
86
|
requirements:
|
87
87
|
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: 1.0.0.
|
89
|
+
version: 1.0.0.beta2
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
94
|
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: 1.0.0.
|
96
|
+
version: 1.0.0.beta2
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: ronin-web-server
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
@@ -164,8 +164,8 @@ dependencies:
|
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
166
|
version: '2.0'
|
167
|
-
description: ronin-web is a Ruby library that provides
|
168
|
-
|
167
|
+
description: ronin-web is a Ruby library that provides common web security commands
|
168
|
+
and additional libraries.
|
169
169
|
email: postmodern.mod3@gmail.com
|
170
170
|
executables:
|
171
171
|
- ronin-web
|
@@ -273,7 +273,7 @@ requirements: []
|
|
273
273
|
rubygems_version: 3.3.26
|
274
274
|
signing_key:
|
275
275
|
specification_version: 4
|
276
|
-
summary: A
|
276
|
+
summary: A collection of common web security commands and libraries.
|
277
277
|
test_files:
|
278
278
|
- spec/cli/ruby_shell_spec.rb
|
279
279
|
- spec/html_spec.rb
|