Skip to content

Commit 24bb6b1

Browse files
committed
Land rapid7#7246 Rex::Socket Gemification
MS-1715
2 parents 6cb331e + 17ab048 commit 24bb6b1

39 files changed

+27
-5807
lines changed

Gemfile.lock

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,14 @@ PATH
3535
redcarpet
3636
rex-arch
3737
rex-bin_tools
38+
rex-core
3839
rex-java
3940
rex-mime
4041
rex-ole
4142
rex-powershell
4243
rex-random_identifier
4344
rex-registry
45+
rex-socket
4446
rex-struct2
4547
rex-text
4648
rex-zip
@@ -85,7 +87,7 @@ GEM
8587
arel (6.0.3)
8688
arel-helpers (2.3.0)
8789
activerecord (>= 3.1.0, < 6)
88-
aruba (0.14.1)
90+
aruba (0.14.2)
8991
childprocess (~> 0.5.6)
9092
contracts (~> 0.9)
9193
cucumber (>= 1.3.19)
@@ -95,7 +97,7 @@ GEM
9597
bcrypt (3.1.11)
9698
bit-struct (0.15.0)
9799
builder (3.2.2)
98-
capybara (2.7.1)
100+
capybara (2.8.1)
99101
addressable
100102
mime-types (>= 1.16)
101103
nokogiri (>= 1.3.3)
@@ -237,7 +239,7 @@ GEM
237239
rex-core
238240
rex-struct2
239241
rex-text
240-
rex-core (0.1.1)
242+
rex-core (0.1.2)
241243
rex-java (0.1.2)
242244
rex-mime (0.1.1)
243245
rex-text
@@ -249,6 +251,8 @@ GEM
249251
rex-random_identifier (0.1.0)
250252
rex-text
251253
rex-registry (0.1.0)
254+
rex-socket (0.1.0)
255+
rex-core
252256
rex-struct2 (0.1.0)
253257
rex-text (0.2.1)
254258
rex-zip (0.1.0)
@@ -263,7 +267,7 @@ GEM
263267
rspec-mocks (3.5.0)
264268
diff-lcs (>= 1.2.0, < 2.0)
265269
rspec-support (~> 3.5.0)
266-
rspec-rails (3.5.1)
270+
rspec-rails (3.5.2)
267271
actionpack (>= 3.0)
268272
activesupport (>= 3.0)
269273
railties (>= 3.0)

lib/msf/core/handler/reverse_http.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
require 'rex/sync/ref'
44
require 'rex/payloads/meterpreter/uri_checksum'
55
require 'rex/post/meterpreter'
6-
require 'rex/parser/x509_certificate'
6+
require 'rex/socket/x509_certificate'
77
require 'msf/core/payload/windows/verify_ssl'
88
require 'rex/user_agent'
99

lib/msf/core/payload/windows/verify_ssl.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# -*- coding: binary -*-
22

33
require 'msf/core'
4-
require 'rex/parser/x509_certificate'
4+
require 'rex/socket/x509_certificate'
55

66
module Msf
77

@@ -25,7 +25,7 @@ def get_ssl_cert_hash(verify_cert, handler_cert)
2525
raise ArgumentError, "Verifying SSL cert is enabled but no handler cert is configured"
2626
end
2727

28-
hash = Rex::Parser::X509Certificate.get_cert_file_hash(handler_cert)
28+
hash = Rex::Socket::X509Certificate.get_cert_file_hash(handler_cert)
2929
print_status("Meterpreter will verify SSL Certificate with SHA1 hash #{hash.unpack("H*").first}")
3030
hash
3131
end

lib/msf/ui/web/comm.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# -*- coding: binary -*-
2+
require 'rex/ui/text/bidirectional_pipe'
23
module Msf
34
module Ui
45
module Web
@@ -83,7 +84,7 @@ def self.create_session_channel(session_id)
8384
end
8485

8586
def self.create_session_pipe(session)
86-
pipe = Rex::IO::BidirectionalPipe.new
87+
pipe = Rex::Ui::BidirectionalPipe.new
8788

8889
@session_pipes[session.id] = pipe
8990

lib/msf/ui/web/console.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# -*- coding: binary -*-
2+
require 'rex/ui/text/bidirectional_pipe'
23
module Msf
34
module Ui
45
module Web
@@ -18,7 +19,7 @@ class WebConsole
1819
attr_accessor :thread
1920

2021
# Wrapper class in case we need to extend the pipe
21-
class WebConsolePipe < Rex::IO::BidirectionalPipe
22+
class WebConsolePipe < Rex::Ui::Text::BidirectionalPipe
2223
def prompting?
2324
false
2425
end

lib/msf/ui/web/driver.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ module Msf
88
module Ui
99
module Web
1010

11-
require 'rex/io/bidirectional_pipe'
11+
require 'rex/ui/text/bidirectional_pipe'
1212
require 'msf/ui/web/console'
1313

1414

lib/rex/io/datagram_abstraction.rb

Lines changed: 0 additions & 26 deletions
This file was deleted.

0 commit comments

Comments
 (0)