Merge branch 'PHP-7.4'

This commit is contained in:
Máté Kocsis 2020-01-27 14:04:19 +01:00
commit d6a6a60ef9
No known key found for this signature in database
GPG Key ID: FD055E41728BF310
2 changed files with 10 additions and 1 deletions

View File

@ -424,7 +424,7 @@ const php_password_algo php_password_algo_argon2id = {
PHP_MINIT_FUNCTION(password) /* {{{ */
{
zend_hash_init(&php_password_algos, 4, NULL, ZVAL_PTR_DTOR, 1);
REGISTER_NULL_CONSTANT("PASSWORD_DEFAULT", CONST_CS | CONST_PERSISTENT);
REGISTER_STRING_CONSTANT("PASSWORD_DEFAULT", "2y", CONST_CS | CONST_PERSISTENT);
if (FAILURE == php_password_algo_register("2y", &php_password_algo_bcrypt)) {
return FAILURE;

View File

@ -0,0 +1,9 @@
--TEST--
Test that the value of PASSWORD_DEFAULT matches PASSWORD_BCRYPT
--FILE--
<?php
echo PASSWORD_DEFAULT . "\n";
echo PASSWORD_BCRYPT . "\n";
--EXPECT--
2y
2y