remailer 0.4.3 → 0.4.4
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.
- data/VERSION +1 -1
- data/lib/remailer/connection.rb +17 -3
- data/lib/remailer/connection/socks5_interpreter.rb +11 -11
- data/remailer.gemspec +2 -2
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.4.
|
1
|
+
0.4.4
|
data/lib/remailer/connection.rb
CHANGED
@@ -325,9 +325,23 @@ class Remailer::Connection < EventMachine::Connection
|
|
325
325
|
debug_notification(:timeout, "Response timed out")
|
326
326
|
send_callback(:on_error)
|
327
327
|
elsif (!@connected)
|
328
|
-
|
329
|
-
|
330
|
-
|
328
|
+
remote_options = @options
|
329
|
+
|
330
|
+
case (@interpreter)
|
331
|
+
when Remailer::Connection::Socks5Interpreter
|
332
|
+
remote_options = @options[:proxy]
|
333
|
+
end
|
334
|
+
|
335
|
+
message = "Timed out before a connection could be established to #{remote_options[:host]}:#{remote_options[:port]}"
|
336
|
+
|
337
|
+
if (@interpreter)
|
338
|
+
message << " using #{@interpreter.label}"
|
339
|
+
end
|
340
|
+
|
341
|
+
connect_notification(false, message)
|
342
|
+
debug_notification(:timeout, message)
|
343
|
+
error_notification(:timeout, message)
|
344
|
+
|
331
345
|
send_callback(:on_error)
|
332
346
|
else
|
333
347
|
send_callback(:on_disconnect)
|
@@ -108,18 +108,18 @@ class Remailer::Connection::Socks5Interpreter < Remailer::Interpreter
|
|
108
108
|
end
|
109
109
|
|
110
110
|
parse do |s|
|
111
|
-
|
112
|
-
|
113
|
-
version, reply, reserved, address_type, address, port = s.slice!(0,10).unpack('CCCCNn')
|
111
|
+
if (s.length >= 10)
|
112
|
+
version, reply, reserved, address_type, address, port = s.slice!(0,10).unpack('CCCCNn')
|
114
113
|
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
114
|
+
[
|
115
|
+
reply,
|
116
|
+
{
|
117
|
+
:address => address,
|
118
|
+
:port => port,
|
119
|
+
:address_type => address_type
|
120
|
+
}
|
121
|
+
]
|
122
|
+
end
|
123
123
|
end
|
124
124
|
|
125
125
|
interpret(0) do
|
data/remailer.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{remailer}
|
8
|
-
s.version = "0.4.
|
8
|
+
s.version = "0.4.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Scott Tadman"]
|
12
|
-
s.date = %q{2011-03-
|
12
|
+
s.date = %q{2011-03-03}
|
13
13
|
s.description = %q{EventMachine SMTP Mail User Agent}
|
14
14
|
s.email = %q{scott@twg.ca}
|
15
15
|
s.extra_rdoc_files = [
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: remailer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.4.
|
5
|
+
version: 0.4.4
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Scott Tadman
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-03-
|
13
|
+
date: 2011-03-03 00:00:00 -05:00
|
14
14
|
default_executable:
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|