3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = base64_encode(random_bytes(54)); // 72 chars $b = $a . random_bytes(33); // Same 72 character prefix, with junk added after the end $hash = password_hash($a, PASSWORD_BCRYPT); // Since $b has junk added to the end, we'd expect this to return // bool(false) var_dump(password_verify($b, $hash));

preferences:
26.87 ms | 408 KiB | 5 Q