From: tony2001
Operating system:
PHP version: 5.4SVN-2012-03-05 (SVN)
Package: OpenSSL related
Bug Type: Bug
Bug description:SSL connections do not timeout
Description:
------------
SSL connections never timeout because poll() isn't even used in
ext/openssl.
Test script:
---------------
server.php:
<?php sleep(20); ?>
client.php:
<?php ini_set('default_socket_timeout',1);
var_dump(file_get_contents("https://localhost/server.php")); ?>
Expected result:
----------------
# time php client.php
Warning: file_get_contents(https://localhost/server.php): failed to open
stream: HTTP request failed! in /tmp/client.php on line 1
bool(false)
real 0m2.024s
user 0m0.012s
sys 0m0.003s
Actual result:
--------------
# time php client.php
string(0) ""
real 0m20.063s
user 0m0.012s
sys 0m0.005s
--
Edit bug report at https://bugs.php.net/bug.php?id=61285&edit=1
--
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=61285&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=61285&r=trysnapshot53
Try a snapshot (trunk):
https://bugs.php.net/fix.php?id=61285&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=61285&r=fixed
Fixed in SVN and need be documented:
https://bugs.php.net/fix.php?id=61285&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=61285&r=alreadyfixed
Need backtrace:
https://bugs.php.net/fix.php?id=61285&r=needtrace
Need Reproduce Script:
https://bugs.php.net/fix.php?id=61285&r=needscript
Try newer version:
https://bugs.php.net/fix.php?id=61285&r=oldversion
Not developer issue:
https://bugs.php.net/fix.php?id=61285&r=support
Expected behavior:
https://bugs.php.net/fix.php?id=61285&r=notwrong
Not enough info:
https://bugs.php.net/fix.php?id=61285&r=notenoughinfo
Submitted twice:
https://bugs.php.net/fix.php?id=61285&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=61285&r=globals
PHP 4 support discontinued:
https://bugs.php.net/fix.php?id=61285&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=61285&r=dst
IIS Stability:
https://bugs.php.net/fix.php?id=61285&r=isapi
Install GNU Sed:
https://bugs.php.net/fix.php?id=61285&r=gnused
Floating point limitations:
https://bugs.php.net/fix.php?id=61285&r=float
No Zend Extensions:
https://bugs.php.net/fix.php?id=61285&r=nozend
MySQL Configuration Error:
https://bugs.php.net/fix.php?id=61285&r=mysqlcfg