openlss / func-bcrypt
Blowfish 加密助手用于密码散列
0.0.12
2013-04-07 02:54 UTC
Requires
- php: >=5.3.2
Requires (Dev)
- openlss/core-boot: ~0.0.1
This package is not auto-updated.
Last update: 2024-09-14 14:46:46 UTC
README
Blowfish 加密助手函数用于密码散列
这些函数用于辅助 bcrypt 散列密码,以提供更安全的密码散列选项
BCrypt 散列密码更强,并具有内联盐值。
用法
$crypted = bcrypt('password'); if(!bcrypt_check('password',$crypted)){ echo "Authorization Denied"; exit; }
参考
(string) bseed($crypted='')
返回一个安全的 Blowfish 种子
(string) bcrypt($plaintext,$seed='')
将明文加密成 Blowfish 散列。如果这是一个现有散列,请传递 $seed
(bool) bcrypt_check($plaintext,$crypted)
检查明文版本与散列是否匹配