double-bag-ftps 0.1.2 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +14 -0
- data/double_bag_ftps.gemspec +1 -1
- data/lib/double_bag_ftps.rb +15 -0
- metadata +12 -13
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '0805592b0f09a1cc49b11af0017ec1433450872e'
|
4
|
+
data.tar.gz: e0000c635ac5128da19631cc415542cd85352ecf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 587dd881f8a0c6a35ec5055732b179815cb5bf1e923811d55318fcfaa3000754822bea0c5dd6e066bbf3c5d12c8efc72a03485eee917ed5db729e09f9aa998d9
|
7
|
+
data.tar.gz: a104e89cf48ab9f795eb0fa1be785787a58802272c4e34992057f02b25a98774f216c7ffc66a5d1e1ad13e0855df00d04b6fd8c27cb2cf2a621c7e6fbe9bf903
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,18 @@
|
|
1
|
+
## 0.1.4
|
2
|
+
|
3
|
+
Buffixes:
|
4
|
+
|
5
|
+
- Fix active mode transfers hanging in some versions of Ruby 2.1
|
6
|
+
|
7
|
+
## 0.1.3
|
8
|
+
|
9
|
+
Bugfixes:
|
10
|
+
|
11
|
+
- Fix active mode transfers hanging in some versions of Ruby 2.2 and
|
12
|
+
2.3
|
13
|
+
|
1
14
|
## 0.1.2
|
15
|
+
|
2
16
|
Bugfixes:
|
3
17
|
|
4
18
|
- Reuse SSL session when creating new sockets
|
data/double_bag_ftps.gemspec
CHANGED
data/lib/double_bag_ftps.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'net/ftp'
|
2
|
+
require 'rubygems'
|
2
3
|
begin
|
3
4
|
require 'openssl'
|
4
5
|
rescue LoadError
|
@@ -109,6 +110,7 @@ class DoubleBagFTPS < Net::FTP
|
|
109
110
|
conn = ssl_socket(conn) # SSL connection now possible after cmd sent
|
110
111
|
else
|
111
112
|
sock = makeport
|
113
|
+
sendport(sock.addr[3], sock.addr[1]) if sendport_needed?
|
112
114
|
if @resume and rest_offset
|
113
115
|
resp = sendcmd('REST ' + rest_offset.to_s)
|
114
116
|
if resp[0] != ?3
|
@@ -129,6 +131,19 @@ class DoubleBagFTPS < Net::FTP
|
|
129
131
|
end
|
130
132
|
private :transfercmd
|
131
133
|
|
134
|
+
# Before ruby-2.2.3, makeport called sendport automatically. After
|
135
|
+
# Ruby 2.3.0, makeport does not call sendport automatically, so do
|
136
|
+
# it ourselves. This change to Ruby's FTP lib has been backported
|
137
|
+
# to Ruby 2.1 since version 2.1.7.
|
138
|
+
def sendport_needed?
|
139
|
+
@sendport_needed ||= begin
|
140
|
+
Gem::Version.new(RUBY_VERSION) >= Gem::Version.new("2.2.3") ||
|
141
|
+
Gem::Version.new(RUBY_VERSION) >= Gem::Version.new("2.1.7") &&
|
142
|
+
Gem::Version.new(RUBY_VERSION) < Gem::Version.new("2.2.0")
|
143
|
+
end
|
144
|
+
end
|
145
|
+
private :sendport_needed?
|
146
|
+
|
132
147
|
def ftps_explicit?; @ftps_mode == EXPLICIT end
|
133
148
|
def ftps_implicit?; @ftps_mode == IMPLICIT end
|
134
149
|
|
metadata
CHANGED
@@ -1,41 +1,41 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: double-bag-ftps
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bryan Nix
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-07-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rspec
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
description:
|
@@ -44,7 +44,7 @@ executables: []
|
|
44
44
|
extensions: []
|
45
45
|
extra_rdoc_files: []
|
46
46
|
files:
|
47
|
-
- .gitignore
|
47
|
+
- ".gitignore"
|
48
48
|
- CHANGELOG.md
|
49
49
|
- LICENSE
|
50
50
|
- README.md
|
@@ -63,20 +63,19 @@ require_paths:
|
|
63
63
|
- lib
|
64
64
|
required_ruby_version: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- -
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
70
70
|
requirements:
|
71
|
-
- -
|
71
|
+
- - ">="
|
72
72
|
- !ruby/object:Gem::Version
|
73
73
|
version: '0'
|
74
74
|
requirements: []
|
75
75
|
rubyforge_project:
|
76
|
-
rubygems_version: 2.
|
76
|
+
rubygems_version: 2.6.12
|
77
77
|
signing_key:
|
78
78
|
specification_version: 4
|
79
79
|
summary: Provides a child class of Net::FTP to support implicit and explicit FTPS.
|
80
|
-
test_files:
|
81
|
-
|
82
|
-
- spec/spec_helper.rb
|
80
|
+
test_files: []
|
81
|
+
has_rdoc:
|