Bug #65137 [Csd->ReO]: stream_select misleads when TLS socket is used
| From: | rdlowrey@php.net | Date: | Wed, 11 Mar 2015 14:13:04 +0000 |
| Subject: | Bug #65137 [Csd->ReO]: stream_select misleads when TLS socket is used | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-191311@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=65137&edit=1
ID: 65137
Updated by: rdlowrey@php.net
Reported by: boen dot robot at gmail dot com
Summary: stream_select misleads when TLS socket is used
-Status: Closed
+Status: Re-Opened
Type: Bug
Package: Streams related
Operating System: Windows Server 2008 R2
PHP Version: 5.5.0
Assigned To: rdlowrey
Block user comment: N
Private report: N
New Comment:
This bug is driving me nuts -- the inherently blocking nature of the existing implementation makes
this difficult to address without rewriting *a lot* of code. Thanks arjen ... Working on it ...
Previous Comments:
------------------------------------------------------------------------
[2015-03-11 12:35:53] arjen at react dot com
This patch triggers this bug again: https://bugs.php.net/bug.php?id=67965
------------------------------------------------------------------------
[2015-03-08 07:52:31] boen dot robot at gmail dot com
Related To: Bug #68853
------------------------------------------------------------------------
[2015-03-08 06:56:59] boen dot robot at gmail dot com
The snapshot build seems to have fixed the original issue I was encountering, but it seems it might
have created a new one... Or maybe this one existed already, and I just hadn't managed witness
it before.
Again only on an encrypted connection... If the server waits for more than default_socket_timeout
before starting to receiving data, while in the mean time the client does a stream_select() with the
connection in $w (i.e. it waits for the server to be ready to receive... supposedly), and $tv_sec
being NULL, stream_select() just hangs at the client, and thus no sending is ever done.
Though for some reason, I can't duplicate it by modifying the echo client/server pair from bug
#68853 accordingly... Feel free to close this particular issue. I'll create a new one if I can
produce a more reliable test case than my current (somewhat large) original code that exhibits this
new issue.
------------------------------------------------------------------------
[2015-03-06 17:35:39] rdlowrey@php.net
Windows snapshots should be available sometime in the next few hours here:
http://windows.php.net/downloads/snaps/php-5.6/
The commit to fix this was added after the final March 05 snapshot. As soon as a newer snapshot is
available you should be able to download a usable windows binary to test. In my own tests this
latest commit resolves the issue from the client/server test case in the related bug #68853.
------------------------------------------------------------------------
[2015-03-06 01:15:13] boen dot robot at gmail dot com
Thank you.
I don't have the setup (or know-how) to compile PHP myself, especially on Windows. If there
were snapshot builds, I'd gladly test this, as well as the related #68853.
I guess I'll just have to wait for... 5.6.8 or whenever a release with that fix in it emerges,
and report back then, if there are new issues.
(Considering how long this has been an issue, I don't mind...)
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=65137
--
Edit this bug report at https://bugs.php.net/bug.php?id=65137&edit=1