Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:88862 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 90689 invoked from network); 18 Oct 2015 23:00:18 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 18 Oct 2015 23:00:18 -0000 Authentication-Results: pb1.pair.com smtp.mail=ircmaxell@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ircmaxell@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.171 as permitted sender) X-PHP-List-Original-Sender: ircmaxell@gmail.com X-Host-Fingerprint: 209.85.212.171 mail-wi0-f171.google.com Received: from [209.85.212.171] ([209.85.212.171:32871] helo=mail-wi0-f171.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 91/C6-06385-57424265 for ; Sun, 18 Oct 2015 19:00:10 -0400 Received: by wijp11 with SMTP id p11so75781812wij.0 for ; Sun, 18 Oct 2015 15:59:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=LG7iyLmzg4286QhIhwHAQc8FENERhObwIF3be28Senc=; b=kL9UC9fj+rgfPhLcPdBmkFdVljGY4up6C8K+h4igcfKwHNy54roTamqYVv9SDA5OCp xpLpHwke7zCL33wMDsL6ZSqBttBAfoeBU46v+P3ilbYJ/FImVhFJPUtyKb8IllH39HH1 CHRHAZ4ZutFzo+HVN/zbcxKnE0exiXP2pw6MUlvca/xxpNPuqVNl+duxZ4iUzl5CvSxs kgQn55W0WMZUOlL/BC9F3rRN5znI1G81m52T7cjhZ0OPyxLkTWvsX1eAgX6+WHu6ubty 4e1km2eYXlg89usa6gnGMlmTFFbyBjh0X+lDl9EHp170biw59w0BHRDe+jj5M0/4UJRb Zsmg== MIME-Version: 1.0 X-Received: by 10.180.93.8 with SMTP id cq8mr15296404wib.24.1445209199104; Sun, 18 Oct 2015 15:59:59 -0700 (PDT) Received: by 10.28.55.18 with HTTP; Sun, 18 Oct 2015 15:59:59 -0700 (PDT) Date: Sun, 18 Oct 2015 18:59:59 -0400 Message-ID: To: "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Subject: Password_hash salt generation refactor From: ircmaxell@gmail.com (Anthony Ferrara) All, With PHP 7 comes random_bytes and random_int. This duplicates some of the logic internally that password_hash uses to generate its salt. I would like to refactor this to unify generation. I've opened a PR against master: https://github.com/php/php-src/pull/1585 I don't feel comfortable pulling against 7 this far into RC status. Perhaps wait until after it goes gold? Or should this target 7.1? It's not a big deal in either direction. Though it does add a side-effect, where if it can't gather enough entropy it will throw an exception and return failure (where prior it would simply make a "best effort". Thoughts? Anthony