[Closed] Fix segfault with old OpenSSL

Issue #9592 has been updated by Tomoyuki C…

Status changed from Open to Closed
% Done changed from 0 to 100

Applied in changeset ruby-200:r45472.

merge revision(s) r45271: [Backport #9592] [Backport #9670]

  • ext/openssl/ossl.c (ossl_make_error): check NULL for unknown
    error reasons with old OpenSSL, and insert a colon iff formatted
    message is not empty.

Bug #9592: Fix segfault with old OpenSSL

  • Author: Nobuyoshi N.
  • Status: Closed
  • Priority: Normal
  • Assignee:
  • Category: ext/openssl
  • Target version: current: 2.2.0
  • ruby -v: r45270
  • Backport: 1.9.3: REQUIRED, 2.0.0: REQUIRED, 2.1: REQUIRED

r44572 以降、古いOpenSSL(0.9.8kで確認)で、SSL connectionに失敗したときにSEGVすることがあります。

$ ruby -rnet/https -e 
/app/vendor/ruby-2.0.0/lib/ruby/2.0.0/net/http.rb:918: [BUG] 
Segmentation fault
ruby 2.0.0p451 (2014-02-24 revision 45167) [x86_64-linux]

r45271 で修正したのでバックポートをお願いします。