ronin-support 0.5.1 → 0.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.editorconfig +11 -0
- data/.github/workflows/ruby.yml +28 -0
- data/.ruby-version +1 -0
- data/.yardopts +1 -1
- data/ChangeLog.md +28 -0
- data/Gemfile +6 -7
- data/README.md +53 -32
- data/Rakefile +1 -2
- data/gemspec.yml +16 -7
- data/lib/ronin/binary.rb +5 -5
- data/lib/ronin/binary/hexdump.rb +5 -5
- data/lib/ronin/binary/hexdump/parser.rb +5 -5
- data/lib/ronin/binary/struct.rb +5 -5
- data/lib/ronin/binary/template.rb +7 -7
- data/lib/ronin/extensions.rb +5 -5
- data/lib/ronin/extensions/enumerable.rb +5 -5
- data/lib/ronin/extensions/file.rb +37 -31
- data/lib/ronin/extensions/ip_addr.rb +6 -7
- data/lib/ronin/extensions/kernel.rb +5 -5
- data/lib/ronin/extensions/meta.rb +5 -5
- data/lib/ronin/extensions/regexp.rb +5 -5
- data/lib/ronin/extensions/resolv.rb +5 -5
- data/lib/ronin/extensions/string.rb +5 -5
- data/lib/ronin/formatting.rb +5 -5
- data/lib/ronin/formatting/binary.rb +5 -5
- data/lib/ronin/formatting/digest.rb +5 -5
- data/lib/ronin/formatting/extensions.rb +5 -5
- data/lib/ronin/formatting/extensions/binary.rb +5 -5
- data/lib/ronin/formatting/extensions/binary/array.rb +6 -6
- data/lib/ronin/formatting/extensions/binary/base64.rb +5 -5
- data/lib/ronin/formatting/extensions/binary/file.rb +5 -5
- data/lib/ronin/formatting/extensions/binary/float.rb +6 -6
- data/lib/ronin/formatting/extensions/binary/integer.rb +6 -6
- data/lib/ronin/formatting/extensions/binary/string.rb +6 -6
- data/lib/ronin/formatting/extensions/digest.rb +5 -5
- data/lib/ronin/formatting/extensions/digest/file.rb +5 -5
- data/lib/ronin/formatting/extensions/digest/string.rb +5 -5
- data/lib/ronin/formatting/extensions/html.rb +5 -5
- data/lib/ronin/formatting/extensions/html/integer.rb +5 -5
- data/lib/ronin/formatting/extensions/html/string.rb +7 -7
- data/lib/ronin/formatting/extensions/http.rb +5 -5
- data/lib/ronin/formatting/extensions/http/integer.rb +6 -6
- data/lib/ronin/formatting/extensions/http/string.rb +7 -7
- data/lib/ronin/formatting/extensions/sql.rb +5 -5
- data/lib/ronin/formatting/extensions/sql/string.rb +15 -13
- data/lib/ronin/formatting/extensions/text.rb +5 -5
- data/lib/ronin/formatting/extensions/text/array.rb +5 -5
- data/lib/ronin/formatting/extensions/text/string.rb +5 -5
- data/lib/ronin/formatting/html.rb +5 -5
- data/lib/ronin/formatting/http.rb +5 -5
- data/lib/ronin/formatting/sql.rb +5 -5
- data/lib/ronin/formatting/text.rb +5 -5
- data/lib/ronin/fuzzing.rb +5 -5
- data/lib/ronin/fuzzing/extensions.rb +5 -5
- data/lib/ronin/fuzzing/extensions/string.rb +5 -5
- data/lib/ronin/fuzzing/fuzzer.rb +5 -5
- data/lib/ronin/fuzzing/fuzzing.rb +7 -7
- data/lib/ronin/fuzzing/mutator.rb +5 -5
- data/lib/ronin/fuzzing/repeater.rb +5 -5
- data/lib/ronin/fuzzing/template.rb +5 -5
- data/lib/ronin/mixin.rb +2 -2
- data/lib/ronin/network.rb +5 -5
- data/lib/ronin/network/dns.rb +5 -5
- data/lib/ronin/network/esmtp.rb +5 -5
- data/lib/ronin/network/extensions.rb +5 -5
- data/lib/ronin/network/extensions/dns.rb +5 -5
- data/lib/ronin/network/extensions/dns/net.rb +5 -5
- data/lib/ronin/network/extensions/esmtp.rb +5 -5
- data/lib/ronin/network/extensions/esmtp/net.rb +5 -5
- data/lib/ronin/network/extensions/http.rb +5 -5
- data/lib/ronin/network/extensions/http/net.rb +5 -5
- data/lib/ronin/network/extensions/http/uri/http.rb +5 -5
- data/lib/ronin/network/extensions/imap.rb +5 -5
- data/lib/ronin/network/extensions/imap/net.rb +5 -5
- data/lib/ronin/network/extensions/pop3.rb +5 -5
- data/lib/ronin/network/extensions/pop3/net.rb +5 -5
- data/lib/ronin/network/extensions/smtp.rb +5 -5
- data/lib/ronin/network/extensions/smtp/net.rb +5 -5
- data/lib/ronin/network/extensions/ssl.rb +5 -5
- data/lib/ronin/network/extensions/ssl/net.rb +5 -5
- data/lib/ronin/network/extensions/tcp.rb +5 -5
- data/lib/ronin/network/extensions/tcp/net.rb +5 -5
- data/lib/ronin/network/extensions/telnet.rb +5 -5
- data/lib/ronin/network/extensions/telnet/net.rb +5 -5
- data/lib/ronin/network/extensions/udp.rb +5 -5
- data/lib/ronin/network/extensions/udp/net.rb +5 -5
- data/lib/ronin/network/ftp.rb +5 -5
- data/lib/ronin/network/http.rb +5 -5
- data/lib/ronin/network/http/exceptions.rb +5 -5
- data/lib/ronin/network/http/exceptions/unknown_request.rb +5 -5
- data/lib/ronin/network/http/http.rb +52 -57
- data/lib/ronin/network/http/proxy.rb +5 -5
- data/lib/ronin/network/imap.rb +5 -5
- data/lib/ronin/network/mixins.rb +5 -5
- data/lib/ronin/network/mixins/dns.rb +5 -5
- data/lib/ronin/network/mixins/esmtp.rb +5 -5
- data/lib/ronin/network/mixins/ftp.rb +5 -5
- data/lib/ronin/network/mixins/http.rb +7 -7
- data/lib/ronin/network/mixins/imap.rb +5 -5
- data/lib/ronin/network/mixins/mixin.rb +5 -5
- data/lib/ronin/network/mixins/pop3.rb +5 -5
- data/lib/ronin/network/mixins/smtp.rb +5 -5
- data/lib/ronin/network/mixins/ssl.rb +5 -5
- data/lib/ronin/network/mixins/tcp.rb +5 -5
- data/lib/ronin/network/mixins/telnet.rb +5 -5
- data/lib/ronin/network/mixins/udp.rb +5 -5
- data/lib/ronin/network/mixins/unix.rb +5 -5
- data/lib/ronin/network/network.rb +5 -5
- data/lib/ronin/network/pop3.rb +5 -5
- data/lib/ronin/network/proxy.rb +5 -5
- data/lib/ronin/network/smtp.rb +5 -5
- data/lib/ronin/network/smtp/email.rb +6 -6
- data/lib/ronin/network/smtp/smtp.rb +5 -5
- data/lib/ronin/network/ssl.rb +7 -7
- data/lib/ronin/network/tcp.rb +5 -5
- data/lib/ronin/network/tcp/proxy.rb +5 -5
- data/lib/ronin/network/tcp/tcp.rb +32 -23
- data/lib/ronin/network/telnet.rb +7 -5
- data/lib/ronin/network/udp.rb +5 -5
- data/lib/ronin/network/udp/proxy.rb +5 -5
- data/lib/ronin/network/udp/udp.rb +28 -26
- data/lib/ronin/network/unix.rb +7 -7
- data/lib/ronin/path.rb +32 -36
- data/lib/ronin/spec/ui/output.rb +5 -5
- data/lib/ronin/support.rb +5 -5
- data/lib/ronin/support/inflector.rb +5 -5
- data/lib/ronin/support/support.rb +5 -5
- data/lib/ronin/support/version.rb +6 -6
- data/lib/ronin/templates.rb +5 -5
- data/lib/ronin/templates/erb.rb +5 -5
- data/lib/ronin/templates/template.rb +5 -5
- data/lib/ronin/ui/output.rb +5 -5
- data/lib/ronin/ui/output/helpers.rb +5 -5
- data/lib/ronin/ui/output/output.rb +17 -21
- data/lib/ronin/ui/output/terminal.rb +5 -5
- data/lib/ronin/ui/output/terminal/color.rb +5 -5
- data/lib/ronin/ui/output/terminal/raw.rb +5 -5
- data/lib/ronin/ui/shell.rb +5 -5
- data/lib/ronin/wordlist.rb +7 -7
- data/ronin-support.gemspec +1 -0
- data/spec/binary/hexdump/parser_spec.rb +22 -22
- data/spec/binary/struct_spec.rb +56 -56
- data/spec/binary/template_spec.rb +106 -104
- data/spec/extensions/enumerable_spec.rb +4 -4
- data/spec/extensions/file_spec.rb +12 -14
- data/spec/extensions/ip_addr_spec.rb +30 -30
- data/spec/extensions/kernel_spec.rb +7 -7
- data/spec/extensions/regexp_spec.rb +69 -69
- data/spec/extensions/resolv_spec.rb +2 -2
- data/spec/extensions/string_spec.rb +30 -29
- data/spec/formatting/binary/array_spec.rb +2 -2
- data/spec/formatting/binary/base64_spec.rb +8 -8
- data/spec/formatting/binary/float_spec.rb +6 -4
- data/spec/formatting/binary/integer_spec.rb +25 -25
- data/spec/formatting/binary/string_spec.rb +32 -30
- data/spec/formatting/digest/string_spec.rb +5 -5
- data/spec/formatting/html/integer_spec.rb +6 -6
- data/spec/formatting/html/string_spec.rb +10 -10
- data/spec/formatting/http/integer_spec.rb +3 -3
- data/spec/formatting/http/string_spec.rb +5 -5
- data/spec/formatting/sql/string_spec.rb +21 -19
- data/spec/formatting/text/array_spec.rb +15 -15
- data/spec/formatting/text/string_spec.rb +33 -33
- data/spec/fuzzing/extensions/string_spec.rb +11 -11
- data/spec/fuzzing/fuzzer_spec.rb +15 -15
- data/spec/fuzzing/fuzzing_spec.rb +5 -5
- data/spec/fuzzing/mutator_spec.rb +15 -15
- data/spec/fuzzing/repeater_spec.rb +7 -7
- data/spec/fuzzing/template_spec.rb +11 -11
- data/spec/mixin_spec.rb +10 -12
- data/spec/network/dns_spec.rb +34 -32
- data/spec/network/ftp_spec.rb +9 -9
- data/spec/network/http/http_spec.rb +237 -144
- data/spec/network/http/proxy_spec.rb +37 -37
- data/spec/network/network_spec.rb +1 -1
- data/spec/network/proxy_spec.rb +19 -19
- data/spec/network/smtp/email_spec.rb +14 -14
- data/spec/network/ssl_spec.rb +9 -9
- data/spec/network/tcp/proxy_spec.rb +9 -7
- data/spec/network/tcp/tcp_spec.rb +161 -118
- data/spec/network/telnet_spec.rb +5 -5
- data/spec/network/udp/udp_spec.rb +123 -96
- data/spec/network/unix_spec.rb +24 -25
- data/spec/path_spec.rb +43 -18
- data/spec/spec_helper.rb +0 -1
- data/spec/support/inflector_spec.rb +4 -4
- data/spec/support_spec.rb +1 -1
- data/spec/templates/erb_spec.rb +3 -3
- data/spec/templates/template_spec.rb +10 -10
- data/spec/ui/shell_spec.rb +15 -15
- data/spec/wordlist_spec.rb +19 -19
- metadata +408 -366
- data/.gemtest +0 -0
data/lib/ronin/templates.rb
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/templates/template'
|
data/lib/ronin/templates/erb.rb
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/templates/template'
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'data_paths/finders'
|
data/lib/ronin/ui/output.rb
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/ui/output/output'
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/ui/output/output'
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/ui/output/terminal/raw'
|
@@ -26,16 +26,12 @@ module Ronin
|
|
26
26
|
# Controls {Output} from Ronin.
|
27
27
|
#
|
28
28
|
module Output
|
29
|
-
@mode = if ($VERBOSE || $DEBUG)
|
30
|
-
|
31
|
-
else
|
32
|
-
:quiet
|
29
|
+
@mode = if ($VERBOSE || $DEBUG) then :verbose
|
30
|
+
else :quiet
|
33
31
|
end
|
34
32
|
|
35
|
-
@handler = if $stdout.tty?
|
36
|
-
|
37
|
-
else
|
38
|
-
Terminal::Raw
|
33
|
+
@handler = if $stdout.tty? then Terminal::Color
|
34
|
+
else Terminal::Raw
|
39
35
|
end
|
40
36
|
|
41
37
|
#
|
@@ -46,7 +42,7 @@ module Ronin
|
|
46
42
|
#
|
47
43
|
# @api semipublic
|
48
44
|
#
|
49
|
-
def
|
45
|
+
def self.verbose?
|
50
46
|
@mode == :verbose
|
51
47
|
end
|
52
48
|
|
@@ -58,7 +54,7 @@ module Ronin
|
|
58
54
|
#
|
59
55
|
# @api semipublic
|
60
56
|
#
|
61
|
-
def
|
57
|
+
def self.quiet?
|
62
58
|
@mode == :quiet
|
63
59
|
end
|
64
60
|
|
@@ -70,7 +66,7 @@ module Ronin
|
|
70
66
|
#
|
71
67
|
# @api semipublic
|
72
68
|
#
|
73
|
-
def
|
69
|
+
def self.silent?
|
74
70
|
@mode == :silent
|
75
71
|
end
|
76
72
|
|
@@ -83,7 +79,7 @@ module Ronin
|
|
83
79
|
#
|
84
80
|
# @api semipublic
|
85
81
|
#
|
86
|
-
def
|
82
|
+
def self.verbose!
|
87
83
|
@mode = :verbose
|
88
84
|
return self
|
89
85
|
end
|
@@ -97,7 +93,7 @@ module Ronin
|
|
97
93
|
#
|
98
94
|
# @api semipublic
|
99
95
|
#
|
100
|
-
def
|
96
|
+
def self.quiet!
|
101
97
|
@mode = :quiet
|
102
98
|
return self
|
103
99
|
end
|
@@ -109,7 +105,7 @@ module Ronin
|
|
109
105
|
#
|
110
106
|
# @since 1.0.0
|
111
107
|
#
|
112
|
-
def
|
108
|
+
def self.silent!
|
113
109
|
@mode = :silent
|
114
110
|
return self
|
115
111
|
end
|
@@ -122,7 +118,7 @@ module Ronin
|
|
122
118
|
#
|
123
119
|
# @api semipublic
|
124
120
|
#
|
125
|
-
def
|
121
|
+
def self.handler
|
126
122
|
@handler
|
127
123
|
end
|
128
124
|
|
@@ -138,7 +134,7 @@ module Ronin
|
|
138
134
|
#
|
139
135
|
# @api semipublic
|
140
136
|
#
|
141
|
-
def
|
137
|
+
def self.handler=(new_handler)
|
142
138
|
@handler = new_handler
|
143
139
|
end
|
144
140
|
end
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/ui/output/terminal/raw'
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
module Ronin
|
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
module Ronin
|
data/lib/ronin/ui/shell.rb
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/ui/output/helpers'
|
data/lib/ronin/wordlist.rb
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
#
|
2
|
-
# Copyright (c) 2006-
|
2
|
+
# Copyright (c) 2006-2021 Hal Brodigan (postmodern.mod3 at gmail.com)
|
3
3
|
#
|
4
|
-
# This file is part of
|
4
|
+
# This file is part of ronin-support.
|
5
5
|
#
|
6
|
-
#
|
6
|
+
# ronin-support is free software: you can redistribute it and/or modify
|
7
7
|
# it under the terms of the GNU Lesser General Public License as published
|
8
8
|
# by the Free Software Foundation, either version 3 of the License, or
|
9
9
|
# (at your option) any later version.
|
10
10
|
#
|
11
|
-
#
|
11
|
+
# ronin-support is distributed in the hope that it will be useful,
|
12
12
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13
13
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14
14
|
# GNU Lesser General Public License for more details.
|
15
15
|
#
|
16
16
|
# You should have received a copy of the GNU Lesser General Public License
|
17
|
-
# along with
|
17
|
+
# along with ronin-support. If not, see <https://www.gnu.org/licenses/>.
|
18
18
|
#
|
19
19
|
|
20
20
|
require 'ronin/fuzzing/template'
|
@@ -107,11 +107,11 @@ module Ronin
|
|
107
107
|
# @yieldparam [String] word
|
108
108
|
# A unique word from the text.
|
109
109
|
#
|
110
|
-
# @return [
|
110
|
+
# @return [Set]
|
111
111
|
# The unique set of words from the text.
|
112
112
|
#
|
113
113
|
def self.parse(text)
|
114
|
-
words_seen =
|
114
|
+
words_seen = Set[]
|
115
115
|
|
116
116
|
text.each_line do |line|
|
117
117
|
line.scan(Regexp::WORD) do |word|
|
data/ronin-support.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 = lambda { |patterns| gem.files & Dir[*patterns] }
|
25
26
|
|
@@ -18,7 +18,7 @@ describe Binary::Hexdump::Parser do
|
|
18
18
|
let(:hexdump) { load_hexdump('hexdump_octal_bytes') }
|
19
19
|
|
20
20
|
it "should unhexdump octal-byte hexdump output" do
|
21
|
-
subject.parse(hexdump).
|
21
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
@@ -30,7 +30,7 @@ describe Binary::Hexdump::Parser do
|
|
30
30
|
let(:hexdump) { load_hexdump('hexdump_hex_bytes') }
|
31
31
|
|
32
32
|
it "should unhexdump hex-byte hexdump output" do
|
33
|
-
subject.parse(hexdump).
|
33
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
34
34
|
end
|
35
35
|
end
|
36
36
|
|
@@ -42,7 +42,7 @@ describe Binary::Hexdump::Parser do
|
|
42
42
|
let(:hexdump) { load_hexdump('hexdump_decimal_shorts') }
|
43
43
|
|
44
44
|
it "should unhexdump decimal-short hexdump output" do
|
45
|
-
subject.parse(hexdump).
|
45
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
46
46
|
end
|
47
47
|
end
|
48
48
|
|
@@ -54,7 +54,7 @@ describe Binary::Hexdump::Parser do
|
|
54
54
|
let(:hexdump) { load_hexdump('hexdump_octal_shorts') }
|
55
55
|
|
56
56
|
it "should unhexdump octal-short hexdump output" do
|
57
|
-
subject.parse(hexdump).
|
57
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
58
58
|
end
|
59
59
|
end
|
60
60
|
|
@@ -66,7 +66,7 @@ describe Binary::Hexdump::Parser do
|
|
66
66
|
let(:hexdump) { load_hexdump('hexdump_hex_shorts') }
|
67
67
|
|
68
68
|
it "should unhexdump hex-short hexdump output" do
|
69
|
-
subject.parse(hexdump).
|
69
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
70
70
|
end
|
71
71
|
end
|
72
72
|
|
@@ -78,7 +78,7 @@ describe Binary::Hexdump::Parser do
|
|
78
78
|
let(:hexdump) { load_hexdump('hexdump_repeated') }
|
79
79
|
|
80
80
|
it "should unhexdump repeated hexdump output" do
|
81
|
-
subject.parse(hexdump).
|
81
|
+
expect(subject.parse(hexdump)).to eq(repeated)
|
82
82
|
end
|
83
83
|
end
|
84
84
|
end
|
@@ -95,7 +95,7 @@ describe Binary::Hexdump::Parser do
|
|
95
95
|
let(:hexdump) { load_hexdump('od_octal_bytes') }
|
96
96
|
|
97
97
|
it "should unhexdump octal-byte hexdump output" do
|
98
|
-
subject.parse(hexdump).
|
98
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
99
99
|
end
|
100
100
|
end
|
101
101
|
|
@@ -107,7 +107,7 @@ describe Binary::Hexdump::Parser do
|
|
107
107
|
let(:hexdump) { load_hexdump('od_octal_shorts') }
|
108
108
|
|
109
109
|
it "should unhexdump octal-shorts hexdump output" do
|
110
|
-
subject.parse(hexdump).
|
110
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
111
111
|
end
|
112
112
|
end
|
113
113
|
|
@@ -119,7 +119,7 @@ describe Binary::Hexdump::Parser do
|
|
119
119
|
let(:hexdump) { load_hexdump('od_octal_ints') }
|
120
120
|
|
121
121
|
it "should unhexdump octal-ints hexdump output" do
|
122
|
-
subject.parse(hexdump).
|
122
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
123
123
|
end
|
124
124
|
end
|
125
125
|
|
@@ -132,7 +132,7 @@ describe Binary::Hexdump::Parser do
|
|
132
132
|
let(:hexdump) { load_hexdump('od_octal_quads') }
|
133
133
|
|
134
134
|
it "should unhexdump octal-quads hexdump output" do
|
135
|
-
subject.parse(hexdump).
|
135
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
136
136
|
end
|
137
137
|
end
|
138
138
|
end
|
@@ -145,7 +145,7 @@ describe Binary::Hexdump::Parser do
|
|
145
145
|
let(:hexdump) { load_hexdump('od_decimal_bytes') }
|
146
146
|
|
147
147
|
it "should unhexdump decimal-byte hexdump output" do
|
148
|
-
subject.parse(hexdump).
|
148
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
149
149
|
end
|
150
150
|
end
|
151
151
|
|
@@ -157,7 +157,7 @@ describe Binary::Hexdump::Parser do
|
|
157
157
|
let(:hexdump) { load_hexdump('od_decimal_shorts') }
|
158
158
|
|
159
159
|
it "should unhexdump decimal-shorts hexdump output" do
|
160
|
-
subject.parse(hexdump).
|
160
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
161
161
|
end
|
162
162
|
end
|
163
163
|
|
@@ -169,7 +169,7 @@ describe Binary::Hexdump::Parser do
|
|
169
169
|
let(:hexdump) { load_hexdump('od_decimal_ints') }
|
170
170
|
|
171
171
|
it "should unhexdump decimal-ints hexdump output" do
|
172
|
-
subject.parse(hexdump).
|
172
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
173
173
|
end
|
174
174
|
end
|
175
175
|
|
@@ -182,7 +182,7 @@ describe Binary::Hexdump::Parser do
|
|
182
182
|
let(:hexdump) { load_hexdump('od_decimal_quads') }
|
183
183
|
|
184
184
|
it "should unhexdump decimal-quads hexdump output" do
|
185
|
-
subject.parse(hexdump).
|
185
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
186
186
|
end
|
187
187
|
end
|
188
188
|
end
|
@@ -197,7 +197,7 @@ describe Binary::Hexdump::Parser do
|
|
197
197
|
let(:hexdump) { load_hexdump('od_named_chars') }
|
198
198
|
|
199
199
|
it "should unhexdump named characters" do
|
200
|
-
subject.parse(hexdump).
|
200
|
+
expect(subject.parse(hexdump)).to eq(data)
|
201
201
|
end
|
202
202
|
end
|
203
203
|
|
@@ -209,7 +209,7 @@ describe Binary::Hexdump::Parser do
|
|
209
209
|
let(:hexdump) { load_hexdump('od_hex_bytes') }
|
210
210
|
|
211
211
|
it "should unhexdump hex-byte hexdump output" do
|
212
|
-
subject.parse(hexdump).
|
212
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
213
213
|
end
|
214
214
|
end
|
215
215
|
|
@@ -221,7 +221,7 @@ describe Binary::Hexdump::Parser do
|
|
221
221
|
let(:hexdump) { load_hexdump('od_hex_shorts') }
|
222
222
|
|
223
223
|
it "should unhexdump hex-shorts hexdump output" do
|
224
|
-
subject.parse(hexdump).
|
224
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
225
225
|
end
|
226
226
|
end
|
227
227
|
|
@@ -233,7 +233,7 @@ describe Binary::Hexdump::Parser do
|
|
233
233
|
let(:hexdump) { load_hexdump('od_hex_ints') }
|
234
234
|
|
235
235
|
it "should unhexdump hex-ints hexdump output" do
|
236
|
-
subject.parse(hexdump).
|
236
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
237
237
|
end
|
238
238
|
end
|
239
239
|
|
@@ -246,7 +246,7 @@ describe Binary::Hexdump::Parser do
|
|
246
246
|
let(:hexdump) { load_hexdump('od_hex_quads') }
|
247
247
|
|
248
248
|
it "should unhexdump hex-quads hexdump output" do
|
249
|
-
subject.parse(hexdump).
|
249
|
+
expect(subject.parse(hexdump)).to eq(ascii)
|
250
250
|
end
|
251
251
|
end
|
252
252
|
end
|
@@ -265,7 +265,7 @@ describe Binary::Hexdump::Parser do
|
|
265
265
|
let(:hexdump) { load_hexdump('od_floats') }
|
266
266
|
|
267
267
|
it "should unhexdump floats" do
|
268
|
-
subject.parse(hexdump).
|
268
|
+
expect(subject.parse(hexdump)).to eq(data)
|
269
269
|
end
|
270
270
|
end
|
271
271
|
|
@@ -283,7 +283,7 @@ describe Binary::Hexdump::Parser do
|
|
283
283
|
let(:hexdump) { load_hexdump('od_doubles') }
|
284
284
|
|
285
285
|
it "should unhexdump doubles" do
|
286
|
-
subject.parse(hexdump).
|
286
|
+
expect(subject.parse(hexdump)).to eq(data)
|
287
287
|
end
|
288
288
|
end
|
289
289
|
|
@@ -295,7 +295,7 @@ describe Binary::Hexdump::Parser do
|
|
295
295
|
let(:hexdump) { load_hexdump('od_repeated') }
|
296
296
|
|
297
297
|
it "should unhexdump repeated hexdump output" do
|
298
|
-
subject.parse(hexdump).
|
298
|
+
expect(subject.parse(hexdump)).to eq(repeated)
|
299
299
|
end
|
300
300
|
end
|
301
301
|
end
|