ronin-payloads 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +6 -1
- data/ChangeLog.md +11 -0
- data/Gemfile +5 -5
- data/data/templates/payload.rb.erb +2 -2
- data/lib/ronin/payloads/builtin/cmd/awk/reverse_shell.rb +3 -0
- data/lib/ronin/payloads/builtin/cmd/bash/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/lua/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/node/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/openssl/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/perl/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/php/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/powershell/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/python/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/cmd/ruby/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/builtin/java/reverse_shell.rb +4 -0
- data/lib/ronin/payloads/cli/commands/list.rb +5 -5
- data/lib/ronin/payloads/cli/commands/show.rb +1 -1
- data/lib/ronin/payloads/cli/encoder_methods.rb +11 -8
- data/lib/ronin/payloads/cli/format_option.rb +2 -2
- data/lib/ronin/payloads/cli/payload_methods.rb +11 -8
- data/lib/ronin/payloads/mixins/tempfile.rb +1 -1
- data/lib/ronin/payloads/payload.rb +1 -0
- data/lib/ronin/payloads/url_payload.rb +1 -1
- data/lib/ronin/payloads/version.rb +1 -1
- data/man/ronin-payloads.1 +7 -7
- data/man/ronin-payloads.1.md +7 -7
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d2ab679d7311dab9baaff45c264e2a651a09530b5790eed2611060b66e776585
|
4
|
+
data.tar.gz: 7058d3c5e5f25f947e46cc651f4d7de2e7e3878578be2b0cb778f35864f2fdfd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d42c63a5fd2d02b157947de808e394fc60f052c22700b073cc632b9c32f40bec44570d09b0141bcfc97dfe28634869cf1e6c2367b62285ec38896b053d66444b
|
7
|
+
data.tar.gz: d87cfacd3e70ad04e553644d0956653ec6b9a6673645dddd14ac63c4699e9fe1f30b98224f0c665035950fe1578a7689e21650438f88eb8c15e1491a7ce704e2
|
data/.rubocop.yml
CHANGED
@@ -34,4 +34,9 @@ Style/FormatStringToken:
|
|
34
34
|
- 'spec/builtin/cmd/powershell/reverse_shell_spec.rb'
|
35
35
|
|
36
36
|
# rubocop does not recognize empty-line continuations
|
37
|
-
|
37
|
+
Style/RedundantLineContinuation:
|
38
|
+
Exclude:
|
39
|
+
- 'lib/ronin/payloads/builtin/shellcode/**/*.rb'
|
40
|
+
Layout/LineContinuationSpacing:
|
41
|
+
Exclude:
|
42
|
+
- 'lib/ronin/payloads/builtin/shellcode/**/*.rb'
|
data/ChangeLog.md
CHANGED
@@ -1,3 +1,14 @@
|
|
1
|
+
### 0.1.2 / 2023-06-09
|
2
|
+
|
3
|
+
* Add missing `require` for {Ronin::Payloads::Encoders::Encoder}.
|
4
|
+
* Added missing descriptions to built-in payloads (@ervinismu).
|
5
|
+
* Documentation fixes and improvements.
|
6
|
+
|
7
|
+
#### CLI
|
8
|
+
|
9
|
+
* Fixed the placeholder `references` URLs in the `ronin-payloads new` template.
|
10
|
+
* Fixed `--format html` and `--format xml` to encode every character.
|
11
|
+
|
1
12
|
### 0.1.1 / 2023-03-01
|
2
13
|
|
3
14
|
* Default the `host` param defined by {Ronin::Payloads::Mixins::BindShell} to
|
data/Gemfile
CHANGED
@@ -12,19 +12,19 @@ gem 'jruby-openssl', '~> 0.7', platforms: :jruby
|
|
12
12
|
# branch: 'main'
|
13
13
|
|
14
14
|
# Ronin dependencies
|
15
|
-
# gem 'ronin-support', '~> 1.0', github:
|
15
|
+
# gem 'ronin-support', '~> 1.0', github: 'ronin-rb/ronin-support',
|
16
16
|
# branch: 'main'
|
17
17
|
|
18
|
-
# gem 'ronin-code-asm', '~> 1.0', github:
|
18
|
+
# gem 'ronin-code-asm', '~> 1.0', github: 'ronin-rb/ronin-code-asm',
|
19
19
|
# branch: 'main'
|
20
20
|
|
21
|
-
# gem 'ronin-post_ex', '~> 0.1', github:
|
21
|
+
# gem 'ronin-post_ex', '~> 0.1', github: 'ronin-rb/ronin-post_ex',
|
22
22
|
# branch: 'main'
|
23
23
|
|
24
|
-
# gem 'ronin-core', '~> 0.1', github:
|
24
|
+
# gem 'ronin-core', '~> 0.1', github: 'ronin-rb/ronin-core',
|
25
25
|
# branch: 'main'
|
26
26
|
|
27
|
-
# gem 'ronin-repos', '~> 0.1', github:
|
27
|
+
# gem 'ronin-repos', '~> 0.1', github: 'ronin-rb/ronin-repos',
|
28
28
|
# branch: 'main'
|
29
29
|
|
30
30
|
group :development do
|
@@ -31,7 +31,7 @@ module Ronin
|
|
31
31
|
#
|
32
32
|
# ## Usage
|
33
33
|
#
|
34
|
-
# ronin-payloads list [options] [
|
34
|
+
# ronin-payloads list [options] [DIR]
|
35
35
|
#
|
36
36
|
# ## Options
|
37
37
|
#
|
@@ -39,14 +39,14 @@ module Ronin
|
|
39
39
|
#
|
40
40
|
# ## Arguments
|
41
41
|
#
|
42
|
-
# [
|
42
|
+
# [DIR] The optional payload directory to list
|
43
43
|
#
|
44
44
|
class List < Command
|
45
45
|
|
46
|
-
usage '[options] [
|
46
|
+
usage '[options] [DIR]'
|
47
47
|
|
48
|
-
argument :
|
49
|
-
|
48
|
+
argument :dir, required: false,
|
49
|
+
desc: 'The optional payload directory to list'
|
50
50
|
|
51
51
|
description 'Lists the available payloads'
|
52
52
|
|
@@ -64,11 +64,11 @@ module Ronin
|
|
64
64
|
def load_encoder(name)
|
65
65
|
Payloads::Encoders.load_class(name)
|
66
66
|
rescue Payloads::ClassNotFound => error
|
67
|
-
print_error
|
67
|
+
print_error(error.message)
|
68
68
|
exit(1)
|
69
69
|
rescue => error
|
70
70
|
print_exception(error)
|
71
|
-
print_error
|
71
|
+
print_error("an unhandled exception occurred while loading encoder #{name}")
|
72
72
|
exit(-1)
|
73
73
|
end
|
74
74
|
|
@@ -84,11 +84,11 @@ module Ronin
|
|
84
84
|
def load_encoder_from(file)
|
85
85
|
Payloads::Encoders.load_class_from_file(file)
|
86
86
|
rescue Payloads::ClassNotFound => error
|
87
|
-
print_error
|
87
|
+
print_error(error.message)
|
88
88
|
exit(1)
|
89
89
|
rescue => error
|
90
90
|
print_exception(error)
|
91
|
-
print_error
|
91
|
+
print_error("an unhandled exception occurred while loading encoder from file #{file}")
|
92
92
|
exit(-1)
|
93
93
|
end
|
94
94
|
|
@@ -101,14 +101,17 @@ module Ronin
|
|
101
101
|
# @param [Hash{Symbol => Object}] kwargs
|
102
102
|
# Additional keyword arguments for {Ronin::Payloads::Encoders::Encoder#initialize}.
|
103
103
|
#
|
104
|
+
# @return [Encoders::Encoder]
|
105
|
+
# The initialized encoder object.
|
106
|
+
#
|
104
107
|
def initialize_encoder(encoder_class,**kwargs)
|
105
108
|
encoder_class.new(**kwargs)
|
106
109
|
rescue Core::Params::ParamError => error
|
107
|
-
print_error
|
110
|
+
print_error(error.message)
|
108
111
|
exit(1)
|
109
112
|
rescue => error
|
110
113
|
print_exception(error)
|
111
|
-
print_error
|
114
|
+
print_error("an unhandled exception occurred while initializing encoder #{encoder_class.id}")
|
112
115
|
exit(-1)
|
113
116
|
end
|
114
117
|
|
@@ -127,11 +130,11 @@ module Ronin
|
|
127
130
|
def validate_encoder(encoder)
|
128
131
|
encoder.validate
|
129
132
|
rescue Core::Params::ParamError, Encoders::ValidationError => error
|
130
|
-
print_error
|
133
|
+
print_error("failed to validate the encoder #{encoder.class_id}: #{error.message}")
|
131
134
|
exit(1)
|
132
135
|
rescue => error
|
133
136
|
print_exception(error)
|
134
|
-
print_error
|
137
|
+
print_error("an unhandled exception occurred while validating the encoder #{encoder.class_id}")
|
135
138
|
exit(-1)
|
136
139
|
end
|
137
140
|
end
|
@@ -50,12 +50,12 @@ module Ronin
|
|
50
50
|
|
51
51
|
xml: -> {
|
52
52
|
require 'ronin/support/encoding/xml'
|
53
|
-
Support::Encoding::XML.method(:
|
53
|
+
Support::Encoding::XML.method(:encode)
|
54
54
|
},
|
55
55
|
|
56
56
|
html: -> {
|
57
57
|
require 'ronin/support/encoding/html'
|
58
|
-
Support::Encoding::HTML.method(:
|
58
|
+
Support::Encoding::HTML.method(:encode)
|
59
59
|
},
|
60
60
|
|
61
61
|
js: -> {
|
@@ -42,11 +42,11 @@ module Ronin
|
|
42
42
|
def load_payload(name)
|
43
43
|
Payloads.load_class(name)
|
44
44
|
rescue Payloads::ClassNotFound => error
|
45
|
-
print_error
|
45
|
+
print_error(error.message)
|
46
46
|
exit(1)
|
47
47
|
rescue => error
|
48
48
|
print_exception(error)
|
49
|
-
print_error
|
49
|
+
print_error("an unhandled exception occurred while loading payload #{name}")
|
50
50
|
exit(-1)
|
51
51
|
end
|
52
52
|
|
@@ -62,11 +62,11 @@ module Ronin
|
|
62
62
|
def load_payload_from(file)
|
63
63
|
Payloads.load_class_from_file(file)
|
64
64
|
rescue Payloads::ClassNotFound => error
|
65
|
-
print_error
|
65
|
+
print_error(error.message)
|
66
66
|
exit(1)
|
67
67
|
rescue => error
|
68
68
|
print_exception(error)
|
69
|
-
print_error
|
69
|
+
print_error("an unhandled exception occurred while loading payload from file #{file}")
|
70
70
|
exit(-1)
|
71
71
|
end
|
72
72
|
|
@@ -79,14 +79,17 @@ module Ronin
|
|
79
79
|
# @param [Hash{Symbol => Object}] kwargs
|
80
80
|
# Additional keyword arguments for {Payload#initialize}.
|
81
81
|
#
|
82
|
+
# @return [Payload]
|
83
|
+
# The initialized payload object.
|
84
|
+
#
|
82
85
|
def initialize_payload(payload_class,**kwargs)
|
83
86
|
payload_class.new(**kwargs)
|
84
87
|
rescue Core::Params::ParamError => error
|
85
|
-
print_error
|
88
|
+
print_error(error.message)
|
86
89
|
exit(1)
|
87
90
|
rescue => error
|
88
91
|
print_exception(error)
|
89
|
-
print_error
|
92
|
+
print_error("an unhandled exception occurred while initializing payload #{payload_class.id}")
|
90
93
|
exit(-1)
|
91
94
|
end
|
92
95
|
|
@@ -105,11 +108,11 @@ module Ronin
|
|
105
108
|
def validate_payload(payload)
|
106
109
|
payload.perform_validate
|
107
110
|
rescue Core::Params::ParamError, ValidationError => error
|
108
|
-
print_error
|
111
|
+
print_error("failed to validate the payload #{payload.class_id}: #{error.message}")
|
109
112
|
exit(1)
|
110
113
|
rescue => error
|
111
114
|
print_exception(error)
|
112
|
-
print_error
|
115
|
+
print_error("an unhandled exception occurred while validating the payload #{payload.class_id}")
|
113
116
|
exit(-1)
|
114
117
|
end
|
115
118
|
end
|
data/man/ronin-payloads.1
CHANGED
@@ -27,31 +27,31 @@ Print help information
|
|
27
27
|
.SH COMMANDS
|
28
28
|
.LP
|
29
29
|
.TP
|
30
|
-
\
|
30
|
+
\fBbuild\fR
|
31
31
|
Builds a payload\.
|
32
32
|
.LP
|
33
33
|
.TP
|
34
|
-
\
|
34
|
+
\fBencode\fR
|
35
35
|
Encodes a payload with one or more payload encoders\.
|
36
36
|
.LP
|
37
37
|
.TP
|
38
|
-
\
|
38
|
+
\fBencoders\fR
|
39
39
|
Lists available encoders\.
|
40
40
|
.LP
|
41
41
|
.TP
|
42
|
-
\
|
42
|
+
\fBirb\fR
|
43
43
|
Starts ronin\-payload\[cq]s interactive Ruby shell\.
|
44
44
|
.LP
|
45
45
|
.TP
|
46
|
-
\
|
46
|
+
\fBlaunch\fR
|
47
47
|
Launches a payload\.
|
48
48
|
.LP
|
49
49
|
.TP
|
50
|
-
\
|
50
|
+
\fBlist\fR
|
51
51
|
Lists available payloads\.
|
52
52
|
.LP
|
53
53
|
.TP
|
54
|
-
\
|
54
|
+
\fBhelp\fR
|
55
55
|
Lists available commands or shows help about a specific command\.
|
56
56
|
.LP
|
57
57
|
.SH AUTHOR
|
data/man/ronin-payloads.1.md
CHANGED
@@ -20,25 +20,25 @@ Runs a `ronin-payloads` *COMMAND*.
|
|
20
20
|
|
21
21
|
## COMMANDS
|
22
22
|
|
23
|
-
|
23
|
+
`build`
|
24
24
|
Builds a payload.
|
25
25
|
|
26
|
-
|
26
|
+
`encode`
|
27
27
|
Encodes a payload with one or more payload encoders.
|
28
28
|
|
29
|
-
|
29
|
+
`encoders`
|
30
30
|
Lists available encoders.
|
31
31
|
|
32
|
-
|
32
|
+
`irb`
|
33
33
|
Starts ronin-payload's interactive Ruby shell.
|
34
34
|
|
35
|
-
|
35
|
+
`launch`
|
36
36
|
Launches a payload.
|
37
37
|
|
38
|
-
|
38
|
+
`list`
|
39
39
|
Lists available payloads.
|
40
40
|
|
41
|
-
|
41
|
+
`help`
|
42
42
|
Lists available commands or shows help about a specific command.
|
43
43
|
|
44
44
|
## AUTHOR
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ronin-payloads
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Postmodern
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-06-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ronin-support
|