rex-socket 0.1.43 → 0.1.45
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/lib/rex/socket/comm/local.rb +6 -3
- data/lib/rex/socket/ssl_tcp.rb +1 -1
- data/lib/rex/socket/version.rb +1 -1
- data/lib/rex/socket.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +3 -4
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: faf5e107e5cabee49fbd28a5007c63151719d74671e2ec97588f23a8bfeebb49
|
4
|
+
data.tar.gz: '04811e5e61dce894070fd82b9210052e24b6bc1c766a0c5497752d5b7ff0b6c2'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6aafffe07f0d89669c785c35b30fb6651c86ff46bf4bbad1f9612e08588b27c6842b74feb13c7816bc383553342fa9e951f52d10e20141e534dbb8e31ea7b8cb
|
7
|
+
data.tar.gz: b8a1683cbb979abb898c3264030b3e20d0590190da1970cb717230060c9c4c1ac99d6a29052c17a07fd229edacdc192caa7a4e2209aa8018799084491360c7fd
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
@@ -433,7 +433,8 @@ class Rex::Socket::Comm::Local
|
|
433
433
|
raise Rex::ConnectionProxyError.new(host, port, type, "The proxy returned a non-OK response"), caller
|
434
434
|
end
|
435
435
|
when 'socks4'
|
436
|
-
|
436
|
+
supports_ipv6 = false
|
437
|
+
setup = [4,1,port.to_i].pack('CCn') + Socket.resolv_nbo(host, supports_ipv6) + Rex::Text.rand_text_alpha(rand(8)+1) + "\x00"
|
437
438
|
size = sock.put(setup)
|
438
439
|
if size != setup.length
|
439
440
|
raise Rex::ConnectionProxyError.new(host, port, type, "Failed to send the entire request to the proxy"), caller
|
@@ -463,11 +464,13 @@ class Rex::Socket::Comm::Local
|
|
463
464
|
end
|
464
465
|
|
465
466
|
if Rex::Socket.is_ipv4?(host)
|
466
|
-
|
467
|
+
accepts_ipv6 = false
|
468
|
+
addr = Rex::Socket.resolv_nbo(host)
|
467
469
|
setup = [5,1,0,1].pack('C4') + addr + [port.to_i].pack('n')
|
468
470
|
elsif Rex::Socket.support_ipv6? && Rex::Socket.is_ipv6?(host)
|
469
471
|
# IPv6 stuff all untested
|
470
|
-
|
472
|
+
accepts_ipv6 = true
|
473
|
+
addr = Rex::Socket.resolv_nbo(host, accepts_ipv6)
|
471
474
|
setup = [5,1,0,4].pack('C4') + addr + [port.to_i].pack('n')
|
472
475
|
else
|
473
476
|
# Then it must be a domain name.
|
data/lib/rex/socket/ssl_tcp.rb
CHANGED
@@ -127,7 +127,7 @@ begin
|
|
127
127
|
# If peerhostname is set, or if hostname looks like a hostname, set the undocumented 'hostname'
|
128
128
|
# attribute on sslsock, which enables the Server Name Indication (SNI)
|
129
129
|
# extension
|
130
|
-
if self.peerhostname
|
130
|
+
if self.peerhostname and not self.peerhostname.strip.empty?
|
131
131
|
self.sslsock.hostname = self.peerhostname
|
132
132
|
elsif !Rex::Socket.dotted_ip?(self.peerhost)
|
133
133
|
self.sslsock.hostname = self.peerhost
|
data/lib/rex/socket/version.rb
CHANGED
data/lib/rex/socket.rb
CHANGED
@@ -211,7 +211,7 @@ module Socket
|
|
211
211
|
#
|
212
212
|
# @deprecated Please use {#getaddress}, {#resolv_nbo}, or similar instead.
|
213
213
|
def self.gethostbyname(host)
|
214
|
-
warn "NOTE: #{self}.#{__method__} is deprecated, use getaddress,
|
214
|
+
warn "NOTE: #{self}.#{__method__} is deprecated, use getaddress, resolv_nbo, or similar instead. It will be removed in the next Major version"
|
215
215
|
if is_ipv4?(host)
|
216
216
|
return [ host, [], 2, host.split('.').map{ |c| c.to_i }.pack("C4") ]
|
217
217
|
end
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rex-socket
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.45
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Metasploit Hackers
|
@@ -93,7 +93,7 @@ cert_chain:
|
|
93
93
|
EknWpNgVhohbot1lfVAMmIhdtOVaRVcQQixWPwprDj/ydB8ryDMDosIMcw+fkoXU
|
94
94
|
9GJsSaSRRYQ9UUkVL27b64okU8D48m8=
|
95
95
|
-----END CERTIFICATE-----
|
96
|
-
date:
|
96
|
+
date: 2023-01-13 00:00:00.000000000 Z
|
97
97
|
dependencies:
|
98
98
|
- !ruby/object:Gem::Dependency
|
99
99
|
name: rake
|
@@ -193,8 +193,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
193
193
|
- !ruby/object:Gem::Version
|
194
194
|
version: '0'
|
195
195
|
requirements: []
|
196
|
-
|
197
|
-
rubygems_version: 2.7.10
|
196
|
+
rubygems_version: 3.1.4
|
198
197
|
signing_key:
|
199
198
|
specification_version: 4
|
200
199
|
summary: The Ruby Exploitation (Rex) Socket Abstraction Library.
|
metadata.gz.sig
CHANGED
Binary file
|