Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:94409 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 53235 invoked from network); 7 Jul 2016 12:13:05 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Jul 2016 12:13:05 -0000 Authentication-Results: pb1.pair.com smtp.mail=cmbecker69@gmx.de; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=cmbecker69@gmx.de; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmx.de designates 212.227.15.19 as permitted sender) X-PHP-List-Original-Sender: cmbecker69@gmx.de X-Host-Fingerprint: 212.227.15.19 mout.gmx.net Received: from [212.227.15.19] ([212.227.15.19:64512] helo=mout.gmx.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 7C/47-18622-F474E775 for ; Thu, 07 Jul 2016 08:13:04 -0400 Received: from [192.168.2.103] ([217.82.227.154]) by mail.gmx.com (mrgmx002) with ESMTPSA (Nemesis) id 0LZhsq-1biPFG1K1c-00lXu2; Thu, 07 Jul 2016 14:12:58 +0200 To: Yasuo Ohgaki References: <9e874892-d682-1c0d-77ad-21d5b44ce25b@gmx.de> Cc: Leigh , Pierre Joye , Dan Ackroyd , PHP internals , Stanislav Malyshev Message-ID: <54093194-3164-2b79-579a-df30d0c411ab@gmx.de> Date: Thu, 7 Jul 2016 14:13:00 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:AbrhQk0w8tND/CCIGY4xCRVCY3VrT9vOGjkM70skh6IY2u+evku hcJ03SWwQKGJvHCkNV3N7g9JEKJPUQQiaNlpoDB5F+0hdGeLIpS0wy9QGQ37H4Wvo+qF6e7 RrJhBPJIkK6KPJIgC3CR2ElNQVW97U1rKeUkbrEVVDGXonSbRwgIbm+nY39qZ7PcWkGQbLM xA4tyz4TBwdV9m0RhfEmg== X-UI-Out-Filterresults: notjunk:1;V01:K0:Ogvvb3H7dTQ=:1sKOdukb4o41djqGz34M6E QKfFk/d/WecoRxC8hPDSQXaCF6MDtlonJ/HnRo3VQDI4uLU+dPN7ztiiP35VFHUBM1cCf0pNK 39diWCDEyCx5qleXtdKHSKycCd22v7Voltib0+CEFWAS5BnGDw8A6Kmjhn8HJTVITjmH8cEbQ jJG4L/6FsP8qXFv6PQ2gcYVABYIvwTo10nQUQl3q8/4HolHqlUncMg3Sln3ehiJU3XquxIG6D 3EfKRw2EpekG3pZgENFf0Rw4z+3cDKqgEAcO2xP8cUaqa/UdAu4Wfb/dD/u1MolXA/zvkxxYO mbDXq8s50oij/EUg5arH4vCQhLIHmppldCvN5XHnbDr+3EQnJ/l9EsOUJxoXhLc37yTSSDqWm XEYFxz2rXIjUydOag16yQFigLwt5HFMXgI+PyVo9MYYGDjHduwMfBUsw3Gp+W6ZtdVekzFKns mkgy7q43+m0cZkcDYgjebzKP68h2SV6b70aNnM4u9bBHU9SXl4bNBvrK1S8FDHAvjsqvsuJrx nWhcjXs6LldGuDZ+nN4rEfl1NU5slrtbdkt7C/hkMkIFMcLfuBhb7Nchu4DFt8P1LcRZzBg/x EXGfYN95FaiUSXAubEagiSWEca464Rg51AuCseDHQxVu0R/J7G/afsKdWXtEQ+Xi/Xxc9SuUs 0jN/VxLql5JbFHTHgxN/eihhMyql78XOnEcJ7rtBqBLlEqqUHBzz7Q5IqeJTXAjgXdyg76SZp 7oFISwII9v9MeXheaiNyJbM+uKsQaBJCNi/ncIzdGD+c/m5H+yAKJIuDrJN2ZXvzEcuvFoksA r36KSWG Subject: Re: [PHP-DEV] Re: [RFC][VOTE] Session ID without hashing From: cmbecker69@gmx.de (Christoph Becker) On 06.07.2016 at 23:30, Yasuo Ohgaki wrote: > > On Wed, Jul 6, 2016 at 9:10 PM, Christoph Becker wrote: >> >> Yes, I am aware that the patch uses php_random_bytes(), but what happens >> when it fails, in which case php_session_create_id() returns null[1]? >> Would it be impossible to use a session in this case? > > php_session_create_id() may return NULL. It's an usual error. Session > module supports session ID creation save handler which may return > anything valid for the type. > > Session module tries to call php_session_create_id() several > places/times. If it could not get valid one, it raises > E_RECOVERABLE_ERROR or E_ERROR eventually. > > Although it's not enabled yet, PHP_FUNCTION(session_create_id) returns > FALSE it fails. Thanks for the explanation, Yasuo. AIUI, the old session module would not fail on such (most likely rare) occasions, however. If that is so, I suggest to note that in the "Backward Incompatible Changes" section of the RFC (so that it would be noted in UPGRADING and the migration guide). -- Christoph M. Becker