PHP.net 说 md5() 和 sha1() 不适合作为密码?

标签 php mysql hash passwords md5

http://www.php.net/manual/en/faq.passwords.php#faq.passwords.fasthash

我将用户密码以散列形式存储在 MySQL 数据库中。这是否意味着这样做是不安全的?如果是,我的替代方案是什么?

最佳答案

您链接到的常见问题解答中的下一个问题讨论了它:How should I hash my passwords, if the common hash functions are not suitable?

来自常见问题解答:

The suggested algorithm to use when hashing passwords is Blowfish, as it is significantly more computationally expensive than MD5 or SHA1, while still being scalable.

接下来的问题是关于盐的。

关于PHP.net 说 md5() 和 sha1() 不适合作为密码?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8110196/

相关文章:

hash - 使用 decl_storage 时,为什么在 StorageMap 中使用 blake2_256 以外的哈希算法

c# - Int32.ToString() 太慢

php - 在 mac 雪豹上启用 php

mysql - 选择 MySQL 语句中的最后一行

mysql - 获得主题帖+便签页的最佳方式是什么?

php - 使用多个内连接

hash - CRC32 与 CRC32C?

php - 如何从 Woocommerce 面包屑中删除 "Home"链接?

javascript - 如何在ajax函数调用中发送var来发送POST?

php - 如何从 laravel Controller 执行外部 shell 命令?