зеркало из https://github.com/github/ruby.git
* lib/net/http.rb: set hostname before call ossl_ssl_set_session.
[Bug #11401][ruby-core:70152][fix GH-964] Patch by @mkarnebeek git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52682 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
2fac41a63e
Коммит
2c97d69052
|
@ -1,3 +1,8 @@
|
||||||
|
Fri Nov 20 14:39:56 2015 SHIBATA Hiroshi <hsbt@ruby-lang.org>
|
||||||
|
|
||||||
|
* lib/net/http.rb: set hostname before call ossl_ssl_set_session.
|
||||||
|
[Bug #11401][ruby-core:70152][fix GH-964] Patch by @mkarnebeek
|
||||||
|
|
||||||
Fri Nov 20 12:53:19 2015 SHIBATA Hiroshi <hsbt@ruby-lang.org>
|
Fri Nov 20 12:53:19 2015 SHIBATA Hiroshi <hsbt@ruby-lang.org>
|
||||||
|
|
||||||
* array.c: clarify docs for take_while/drop_while samples.
|
* array.c: clarify docs for take_while/drop_while samples.
|
||||||
|
|
|
@ -918,12 +918,12 @@ module Net #:nodoc:
|
||||||
@socket.write(buf)
|
@socket.write(buf)
|
||||||
HTTPResponse.read_new(@socket).value
|
HTTPResponse.read_new(@socket).value
|
||||||
end
|
end
|
||||||
|
# Server Name Indication (SNI) RFC 3546
|
||||||
|
s.hostname = @address if s.respond_to? :hostname=
|
||||||
if @ssl_session and
|
if @ssl_session and
|
||||||
Process.clock_gettime(Process::CLOCK_REALTIME) < @ssl_session.time.to_f + @ssl_session.timeout
|
Process.clock_gettime(Process::CLOCK_REALTIME) < @ssl_session.time.to_f + @ssl_session.timeout
|
||||||
s.session = @ssl_session if @ssl_session
|
s.session = @ssl_session if @ssl_session
|
||||||
end
|
end
|
||||||
# Server Name Indication (SNI) RFC 3546
|
|
||||||
s.hostname = @address if s.respond_to? :hostname=
|
|
||||||
if timeout = @open_timeout
|
if timeout = @open_timeout
|
||||||
while true
|
while true
|
||||||
raise Net::OpenTimeout if timeout <= 0
|
raise Net::OpenTimeout if timeout <= 0
|
||||||
|
|
Загрузка…
Ссылка в новой задаче