Bug #73711 [Asn->Csd]: Segfault in openssl_pkey_new when generating DSA or DH key

From: Date: Sun, 23 Apr 2017 19:30:40 +0000
Subject: Bug #73711 [Asn->Csd]: Segfault in openssl_pkey_new when generating DSA or DH key
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-208728@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=73711&edit=1 ID: 73711 Updated by: bukka@php.net Reported by: margusk at gmail dot com Summary: Segfault in openssl_pkey_new when generating DSA or DH key -Status: Assigned +Status: Closed Type: Bug Package: OpenSSL related PHP Version: 7.1.0 Assigned To: bukka Block user comment: N Private report: N New Comment: Automatic comment on behalf of bukka Revision: http://git.php.net/?p=php-src.git;a=commit;h=366b1640d09b982ebc69001bcb476268ab668ab8 Log: Fix bug #73711 (Segfault in openssl_pkey_new when generating DSA or DH key) Previous Comments: ------------------------------------------------------------------------ [2016-12-10 17:04:40] margusk at gmail dot com Description: ------------ When generating new DSA or DH key using openssl_pkey_new(), then script terminates with Segmentation Fault. The problem lies in method php_openssl_generate_private_key() (ext/openssl/openssl.c), where "dsaparam" and "dhparam" variables are not initialized. Both PHP 7.0 and 7.1 are affected. Test script: --------------- <?php $k = openssl_pkey_new (array ("private_key_type" => OPENSSL_KEYTYPE_DSA)); echo "Success!"; ?> Expected result: ---------------- Success! Actual result: -------------- Segmentation Fault ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=73711&edit=1

« previous php.bugs (#208728) next »