diff --git a/modules/user/user.install b/modules/user/user.install index 75fca65..6ef2ca8 100644 --- a/modules/user/user.install +++ b/modules/user/user.install @@ -421,6 +421,12 @@ function user_update_7000(&$sandbox) { $result = db_query_range("SELECT uid, pass FROM {users} WHERE uid > 0 ORDER BY uid", $sandbox['user_from'], $count); foreach ($result as $account) { $has_rows = TRUE; + + // If the $account->pass value is not a MD5 hash then skip it. + if ($account->pass[0] == '$' || ($account->pass[0] == 'U' && $account->pass[1] == '$')) { + continue; + } + $new_hash = user_hash_password($account->pass, $hash_count_log2); if ($new_hash) { // Indicate an updated password.