开发者

Sensible Doctrine Expression and Zend_Auth setCredentialTreatment()

开发者 https://www.devze.com 2022-12-23 12:07 出处:网络
How to create reasonable expression to store password in database using Doctrine and Zend_Auth::setCredentialTreatment()?

How to create reasonable expression to store password in database using Doctrine and Zend_Auth::setCredentialTreatment()?

I don't want to use md5() and the code must be portable, and with salt.

I would call this not easy one to guess:

setCredentialTreatment("SHA1(CONCAT(username, SHA1(CONCAT(username, ?)))");

but it is not portable to all databases.

Seems that Doctrine_Expression has only 开发者_如何学Gomd5 expression portability.


Why not write your own Zend_Auth_Adapter?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号