watobo 0.9.15 → 0.9.16
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.md +10 -2
- data/lib/watobo/core/session.rb +2 -2
- data/lib/watobo/mixins/shapers.rb +11 -10
- data/lib/watobo.rb +1 -1
- metadata +1 -1
data/CHANGELOG.md
CHANGED
@@ -1,7 +1,15 @@
|
|
1
|
+
Version 0.9.16
|
2
|
+
===
|
3
|
+
Fixes
|
4
|
+
---
|
5
|
+
**General**
|
6
|
+
* double insert of Content-Length header
|
7
|
+
* bad markdown format of CHANGELOG
|
8
|
+
|
1
9
|
Version 0.9.15
|
2
|
-
|
10
|
+
===
|
3
11
|
Fixes
|
4
|
-
|
12
|
+
---
|
5
13
|
**General**
|
6
14
|
* improved socket handling
|
7
15
|
* fixed some UTF-8 issues in passive modules
|
data/lib/watobo/core/session.rb
CHANGED
@@ -219,7 +219,7 @@ module Watobo#:nodoc: all
|
|
219
219
|
else
|
220
220
|
# puts "========== Add Headers"
|
221
221
|
|
222
|
-
request.
|
222
|
+
request.set_header("Connection", "close") #if not use_proxy
|
223
223
|
|
224
224
|
data = request.join
|
225
225
|
unless request.has_body?
|
@@ -602,7 +602,7 @@ end
|
|
602
602
|
#auth_request.removeHeader("Authorization")
|
603
603
|
#auth_request.removeHeader("Connection")
|
604
604
|
|
605
|
-
auth_request.set_header("Connection", "
|
605
|
+
auth_request.set_header("Connection", "close")
|
606
606
|
|
607
607
|
msg = "NTLM " + t3.encode64
|
608
608
|
auth_request.addHeader("Authorization", msg)
|
@@ -365,20 +365,21 @@ module Watobo#:nodoc: all
|
|
365
365
|
def set_header(header, value)
|
366
366
|
begin
|
367
367
|
new_header = "#{header}: #{value}\r\n"
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
368
|
+
self.each_with_index do |h, i|
|
369
|
+
if h =~ /^#{Regexp.quote(header)}:/i
|
370
|
+
h.replace(new_header)
|
371
|
+
return true
|
372
|
+
end
|
373
|
+
|
374
|
+
if h.strip.empty? or i == self.length-1
|
375
|
+
self.insert(i, new_header)
|
376
|
+
return true
|
377
|
+
end
|
376
378
|
end
|
377
|
-
end
|
378
379
|
rescue => bang
|
379
380
|
puts bang
|
380
381
|
end
|
381
|
-
|
382
|
+
return false
|
382
383
|
end
|
383
384
|
|
384
385
|
# sets post data
|
data/lib/watobo.rb
CHANGED