shadowsocks-manager
shadowsocks-manager copied to clipboard
md5 hash method is not secure
Use md5(username + password) to store login password is not secure, please consider use sha256. 用 md5(username + password) 的方式存储密码是不安全的,建议至少使用 sha256.
因为第一个版本用的是这种方法,现在一直没有改动,已经在用的用户改动起来比较麻烦
可以通过登录时更新密码的方式平滑过度,或者直接再加盐 hash,脚本处理 DB 中已有记录。
建议更新, 类似ss panel加盐的办法. 密码通过email取回的方法都是没问题的
如果可以实现平滑过度的话是否可以改为Sha 256。 比如把储存密码的Column 格式改成 {method: 'sha256', hash:'xxxxxx', salt: ''} 如果看到旧格式就使用旧验证,如果验证成功就更新到新的格式
SHA256+salt就安全了?密码学原则:不要自己发明实施方法。 为什么不直接scrypt, bcrypt或PBKDF2 https://security.stackexchange.com/q/133239/117921