[ruby-cvs:67370] normal:r60189 (trunk): webrick: fix up r60172

normal at ruby-lang.org normal at ruby-lang.org
Mon Oct 16 13:33:53 JST 2017


normal	2017-10-16 13:33:53 +0900 (Mon, 16 Oct 2017)

  New Revision: 60189

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=60189

  Log:
    webrick: fix up r60172
    
    By making the socket non-blocking in r60172, TLS/SSL negotiation
    via the SSL_accept function must handle non-blocking sockets
    properly and retry on SSL_ERROR_WANT_READ/SSL_ERROR_WANT_WRITE.
    OpenSSL::SSL::SSLSocket#accept cannot do that properly with a
    non-blocking socket, so it must use non-blocking logic of
    OpenSSL::SSL::SSLSocket#accept_nonblock.
    
    Thanks to MSP-Greg (Greg L) for finding this.
    
    * lib/webrick/server.rb (start_thread): use SSL_accept properly
      with non-blocking socket.
      [Bug #14013] [Bug #14005]

  Modified files:
    trunk/lib/webrick/server.rb


More information about the ruby-cvs mailing list