From ce920d9c1ba7305a6e49aae2d3d0c523525297da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20=C3=81lvarez?= Date: Tue, 5 Nov 2019 10:32:39 +0100 Subject: [PATCH] added password_hash --- index.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/index.php b/index.php index c021f78..8312b24 100644 --- a/index.php +++ b/index.php @@ -65,6 +65,13 @@ if ($action == 'reset') { $t2 = (microtime(true) - $t1) * 1000; $result .= sprintf("%-15s %.3f %3d %s\n", $algo, $t2, strlen($r), $r); } + + // password_hash(PASSWORD_DEFAULT) + $t1 = microtime(true); + $r = password_hash($str, PASSWORD_DEFAULT); + $t2 = (microtime(true) - $t1); + $result .= sprintf("%-15s %.3f %3d %s\n", 'password_hash', $t2, strlen($r), $r); + $result = trim($result); $help = 'hash';