ruby-changes:44185
From: nagachika <ko1@a...>
Date: Mon, 26 Sep 2016 23:41:21 +0900 (JST)
Subject: [ruby-changes:44185] nagachika:r56258 (ruby_2_3): merge revision(s) 55057:
nagachika 2016-09-26 23:41:15 +0900 (Mon, 26 Sep 2016) New Revision: 56258 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=56258 Log: merge revision(s) 55057: * ext/openssl/ossl_pkcs12.c (ossl_pkcs12_initialize): pop errors leaked by PKCS12_parse(). This is a bug in OpenSSL, which exists in the versions before the version 1.0.0t, 1.0.1p, 1.0.2d. Modified directories: branches/ruby_2_3/ Modified files: branches/ruby_2_3/ChangeLog branches/ruby_2_3/ext/openssl/ossl_pkcs12.c branches/ruby_2_3/version.h Index: ruby_2_3/version.h =================================================================== --- ruby_2_3/version.h (revision 56257) +++ ruby_2_3/version.h (revision 56258) @@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_3/version.h#L1 #define RUBY_VERSION "2.3.2" #define RUBY_RELEASE_DATE "2016-09-26" -#define RUBY_PATCHLEVEL 190 +#define RUBY_PATCHLEVEL 191 #define RUBY_RELEASE_YEAR 2016 #define RUBY_RELEASE_MONTH 9 Index: ruby_2_3/ext/openssl/ossl_pkcs12.c =================================================================== --- ruby_2_3/ext/openssl/ossl_pkcs12.c (revision 56257) +++ ruby_2_3/ext/openssl/ossl_pkcs12.c (revision 56258) @@ -165,8 +165,12 @@ ossl_pkcs12_initialize(int argc, VALUE * https://github.com/ruby/ruby/blob/trunk/ruby_2_3/ext/openssl/ossl_pkcs12.c#L165 BIO_free(in); pkey = cert = ca = Qnil; + /* OpenSSL's bug; PKCS12_parse() puts errors even if it succeeds. + * Fixed in OpenSSL 1.0.0t, 1.0.1p, 1.0.2d */ + ERR_set_mark(); if(!PKCS12_parse(pkcs, passphrase, &key, &x509, &x509s)) ossl_raise(ePKCS12Error, "PKCS12_parse"); + ERR_pop_to_mark(); pkey = rb_protect((VALUE(*)_((VALUE)))ossl_pkey_new, (VALUE)key, &st); /* NO DUP */ if(st) goto err; Index: ruby_2_3/ChangeLog =================================================================== --- ruby_2_3/ChangeLog (revision 56257) +++ ruby_2_3/ChangeLog (revision 56258) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_3/ChangeLog#L1 +Mon Sep 26 23:34:09 2016 Kazuki Yamaguchi <k@r...> + + * ext/openssl/ossl_pkcs12.c (ossl_pkcs12_initialize): pop errors + leaked by PKCS12_parse(). This is a bug in OpenSSL, which exists + in the versions before the version 1.0.0t, 1.0.1p, 1.0.2d. + Mon Sep 26 23:10:43 2016 NARUSE, Yui <naruse@r...> * vm_dump.c (backtrace): use rip in the saved context for the case Property changes on: ruby_2_3 ___________________________________________________________________ Modified: svn:mergeinfo Merged /trunk:r55057 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/