3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $hash = '$2y$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG'; $test = crypt("password", $hash); echo "$2y string: $test<br />"; $pass = ($test == $hash); echo "$2y test status: " . ( $pass ? "Pass" : "Fail") . "<br />"; $hash = '$2a$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG'; $test = crypt("password", $hash); echo "$2a string: $test<br />"; $pass = ($test == $hash); echo "$2a test status: " . ( $pass ? "Pass" : "Fail") . "<br />"; $hash = '$2x$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG'; $test = crypt("password", $hash); echo "$2x string: $test<br />"; $pass = ($test == $hash); echo "$2x test status: " . ( $pass ? "Pass" : "Fail") . "<br />";
Output for 5.3.7 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
$2y string: $2y$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG<br />$2y test status: Pass<br />$2a string: $2a$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG<br />$2a test status: Pass<br />$2x string: $2x$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG<br />$2x test status: Pass<br />
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.3.2 - 5.3.6
$2y string: $2mV0NZp92R3g<br />$2y test status: Fail<br />$2a string: $2a$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG<br />$2a test status: Pass<br />$2x string: $2mV0NZp92R3g<br />$2x test status: Fail<br />
Output for 5.3.0 - 5.3.1
$2y string: $2SXu7evaw9i.<br />$2y test status: Fail<br />$2a string: $2a$04$usesomesillystringfore7hnbRJHxXVLeakoG8K30oukPsA.ztMG<br />$2a test status: Pass<br />$2x string: $2SXu7evaw9i.<br />$2x test status: Fail<br />
Output for 4.3.0 - 5.2.17

Process exited with code 139.