Skip to content

Instantly share code, notes, and snippets.

@andrewfenn
andrewfenn / mysql_old_password.php
Last active February 26, 2024 13:16
PHP Reimplementation of Mysql's old_password function which no longer exists in newer versions
<?php
/** Creates an old mysql hash compatiable with the old_password
function that no longer exists in mysql */
function mysql_old_password($password) {
if ($password == '') {
return '';
}
$nr = 1345345333;