Issue #12428 has been updated by CHEOLHO JEON.

File opensslcrash.rb added

----------------------------------------
Bug #12428: OpenSSL::PKey::RSA.public_encrypt crashes ruby when initiated without key size.
https://bugs.ruby-lang.org/issues/12428#change-58846

* Author: CHEOLHO JEON
* Status: Open
* Priority: Normal
* Assignee: openssl
* ruby -v: ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin15]
* Backport: 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN
----------------------------------------
Hi, I think I found a bug. OpenSSL::PKey::RSA initiated without keysize crashes when public_encrypt is called.
Below script will crash ruby (it is attached as opensslcrash.rb)

require('openssl')
p = OpenSSL::PKey::RSA.new
p.public_encrypt('hi')

I'm attaching error message(ruby opensslcrash.rb &> error_message.txt) and crash reports under /Users/CJeon/Library/Logs/DiagnosticReports.

Let me know if you guys need further information. Thanks!


---Files--------------------------------
error_message.txt (7.03 KB)
crash.tar (149 KB)
opensslcrash.rb (276 Bytes)


-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>