3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $bcrypt = '$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC'; $bcryptNeedsRehash = preg_replace('/\$\d{2}\$/', '\$' . 11 . '\$', $bcrypt); var_dump($bcrypt, $bcryptNeedsRehash); var_dump(password_hash('qG$4%7fM', PASSWORD_BCRYPT, array('cost'=>13)));
Output for 7.1.0
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$xFRXp/GlsViGl5Q3fOb7L.7jmfM7MiM8R1Z.vTtIJKAEj5uywaZci"
Output for 7.0.14
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$aSV29.neGjb6q0sz/iZFROeO9WBo10f/AeFLPC779BTc0TRdrsSPm"
Output for 7.0.12
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$9TtHwfnx2aDOb8ULovMHTugh4VuJLWsa3YCkSxcmPE2nt05nWfewm"
Output for 7.0.6
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$PCpEhe4gwOA75f2LMLvXBuVZBY/Zz7b8WearG6f7dusrscw.M7njO"
Output for 7.0.5
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$oBJZedH90Zv6vms5o1t2HOBqReJ/eu9RKyTblMvYiVbhMOXkObL4W"
Output for 7.0.4
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$qZnGRWC1hDj1XiWz18xx9e8t5k.x9TDhP7O2rZ0QbPSjOeYL3iNPi"
Output for 7.0.3
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$KSIfx/CFT/9z9.mdUwAxjO3np71KrCA8/XL8uY/xru3P04IT7xliG"
Output for 7.0.2
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$ZPB3Gi46GbFegOPHDxwch.qQRz8I8PVd/P65YUIUCRKhmsvl6WbxK"
Output for 7.0.1
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$oXiZC3QUPU9yAgegKQJe1.aG.QpZvhtj/qY8kFrFbPVhCwx6RBIVy"
Output for 7.0.0
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$0GimX7OhRM/2CAyY0TQppeQzrG2ZF1Kq43G4m554OCZU.NLN20Kpe"
Output for hhvm-3.12.0
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$MlTOB3ShvwvI5RPc0K3dkeoKEdQSRoikdFlVuT34gn76zJn38D8s."
Output for hhvm-3.10.0
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$uhkxeba9EzQDO.HOVksPkOE8jvdn83GZavOt3kBPL3b.ilRLEXE4i"
Output for 5.6.28
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$lWh6y359LSpF/iGO8.Djbe/d0muJngDvmjUQG1CjcXPfdVf.YZUJ2"
Output for 5.6.21
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$51Wd/uEcPnC16CMpvjfl8OyGcfR7uAtKu7QTCU0ITyB1qSrGUFaiC"
Output for 5.6.20
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$ZyO2NfLduj7SempYAmym..Y4Bf5Ko0f6NS97JkG5tgqpvN5xei2yq"
Output for 5.6.19
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$OFgGARU57WtNtkKKGY/kBeaO2F/6qUzIr0PY/.TRRY8bJmiPueMuS"
Output for 5.6.18
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$PLvBBpAeV4t4RpOEsXrC4OpDGg4b7g7a47o6Frxy6ndUSOtI8sMPS"
Output for 5.6.17
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$H/ZV.KIqIyv9zp81f5OOI.WF38WnSEpfFR6EHFkCYMkRIBas1Gvhm"
Output for 5.6.16
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$m5auBHx7aDK/cTf7//wdSereHarHY06Rn2nqsD/U1VEkerniCqTHG"
Output for 5.6.15
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$0fNl2cnjBJJjPCFhkeckxe2HQFHkbH4bmr8iQ0GJSXQtxWgk4jyv."
Output for 5.6.14
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$y4Ehd/LD12D3peF0uBUnee70JSHcS9yvmHtpZ4G19APPAWWgGBk5W"
Output for 5.6.13
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$lVAyCYVyPDUUHiOsZzxBTOXnEfibXWYfNKtmNDqa9avicg3ls.wYK"
Output for 5.6.12
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$n198RroQEbSSduvYZ6.cF.r6WoXsGMhHRSRCC9K0bMwMz6ZsNbF72"
Output for 5.6.11
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$4Efih85aw6uqJVKrwH3TXO.mQXZGiDbwJINa7FBOCv1E8cdxEeII."
Output for 5.6.10
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$8NOsLhzgzZSPF4EnUOzaKeiYmffEzSEUDnFzKhDmQGpECio1DWvvS"
Output for 5.6.9
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$92uK34Vaes0gPjOOguNTmeziu8mbU2joY5x4tq6HB/8FEwxYmrgBe"
Output for 5.6.8
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$9URYdafJXKyfbqqiUv4Coeb0qQ78KfttejXWGJFH8U5Fwz0BCQpPW"
Output for 5.6.7
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$4ikDETrrDUfa7jrjzs9XRe5UVayJ/yvMn2Qh.JSjilSxajroUFVK."
Output for 5.5.35
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$.CMHJgz4PKjnIxvhmiVKCOkcelc9PNogODpS/UaFR3X5RCnAZ.L2W"
Output for 5.5.34
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$J5J5ooTxhdReOm6VmSnmguGF96uSVu5h/eBrbiKTrrPQYQIU8p6AW"
Output for 5.5.33
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$HnK2PyDz9KFiWnBlseS6a.PwDYTzYH7Roq45FOUMyP2IYcnwHeSWO"
Output for 5.5.32
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$5H8r6nd/WIdqp51WlOQVxetORB.1m.pxffkpTq1QQJeMiBIm/1jl6"
Output for 5.5.31
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$z3EV965K7Ap0QtofxtlWMOKoF7v6qBQhFVV4ZK7UO.lBM2ACK4iv2"
Output for 5.5.30
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$7p//Y5e/BMI4qNkeFVfC5uf0Ri8LGx6m9T9NlIb7wDw23pmGXuDea"
Output for 5.5.29
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$4et.NUgE/fMZ2dSNQKxXneMJ/fRhyuF4q22qKEiqtW8SS6Zp32BIi"
Output for 5.5.28
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$9/BgV7chyA4dSavXAeEg2espXq0YFevthWsdk14EoThF.cGmcE0me"
Output for 5.5.27
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$VA8XBxhd7LnM7EfQZRpjM.w1mSFOQmUR70KuZCP/WOsZp5bsd0siu"
Output for 5.5.26
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$jiAk8k6KRWf2krqlW4cOHOv40qhSp3rD8s4RPPPSHIHcOlAe6cHJu"
Output for 5.5.25
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$G3zHo1EZrJEgererO5cFt.r8pApW53H5f6TX27p70U2ZEatDYtKeu"
Output for 5.5.24
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2y$13$XxewcevoFU7VrOhtJUPDROOEXcwliBlbdpoSpETb74JOFb2xeiIvm"
Output for 5.0.0 - 5.4.45
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" Fatal error: Call to undefined function password_hash() in /in/LPRaq on line 6
Process exited with code 255.
Output for 4.4.5 - 4.4.9
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" Fatal error: Call to undefined function: password_hash() in /in/LPRaq on line 6
Process exited with code 255.
Output for 4.3.2 - 4.4.4
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" Fatal error: Call to undefined function: password_hash() in /in/LPRaq on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1
string(60) "$2a$12$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" string(60) "$2a$11$9SIfjYSVOTw8xFn98DadmOYKMSyReSktMvm/tfiLFDYb.oGvO8LEC" Fatal error: Call to undefined function: password_hash() in /in/LPRaq on line 6