Bug #69524 [NEW]: openssl-pkey-get-public() kill mysql(i) connection with ssl
From: js at xim dot de
Operating system: Linux Debian
PHP version: 5.6.8
Package: MySQLi related
Bug Type: Bug
Bug description:openssl-pkey-get-public() kill mysql(i) connection with ssl
Description:
------------
mysqli => Uptime: 453701 Threads: 2 Questions: 34649 Slow queries: 0
Opens: 299 Flush tables: 1 Open tables: 151 Queries per second avg:
0.076
mysqli => Resource id #10
Warning: mysqli::stat(): SSL operation failed with code 1. OpenSSL Error
messages:
error:0906D06C:PEM routines:PEM_read_bio:no start line in ~/test.php on
line 17
Warning: mysqli::stat(): MySQL server has gone away in ~/test.php on
line 17
mysqli =>
---------------------
php version 5.6.6 works but not after :(
Test script:
---------------
$mysqli = mysqli_init();
if(!$mysqli) { exit(1);}
if(!$mysqli->real_connect('host', 'user', '*********',
'information_schema', 3306, NULL, MYSQLI_CLIENT_SSL)) { exit(2); }
echo 'mysqli => ' . $mysqli->stat() . "\n";
$openssl_pkey_get_public = openssl_pkey_get_public('-----BEGIN PUBLIC
KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA6ZkX4HXSiL5YPdaHeAIZ
IsE+jOTdQQzl2R8geQuOB2ODtlSUzMSWEH1o4AQtdTdoQljdiUfoUQQUaMAVj4K9
QsPV8I+by3nhR2kkgjkobspnxfTbMnVkhNlAAeBOrVDO1OF32r/SWrHH1W+WnjRp
g+60bAFvO06OEfVjOTlc4jJAuQq1BCuHalU88yb6wED6A9iP9FLQrQDtKUhTNXRe
v/iBpCKTDGzakao6hJspNrw8sS2FsdzQ8TZdlJ4jTaT8DjMGYsu29Mrov0ybUk0D
zG1Uk+os/0Bz1BnNcCIqRNuNQo5zjOOTE3DkK1Q9wse1TjEi/cCn74H9OWpSlYY3
CQIDAQAB
-----END PUBLIC KEY-----');
echo 'mysqli => ' . print_r($openssl_pkey_get_public,true) . "\n";
echo 'mysqli => ' . $mysqli->stat() . "\n";
$mysqli->close();
--
Edit bug report at https://bugs.php.net/bug.php?id=69524&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=69524&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=69524&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=69524&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=69524&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=69524&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=69524&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=69524&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=69524&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=69524&r=support
Expected behavior: https://bugs.php.net/fix.php?id=69524&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=69524&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=69524&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=69524&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=69524&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=69524&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=69524&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=69524&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=69524&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=69524&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=69524&r=mysqlcfg
Thread (9 messages)
- js at xim dot de