Prestashop: trying to decode password

笑着哭i 提交于 2019-12-24 09:49:31

问题


i'm developing a backend in Asp.NET for Prestashop. I've a small problem: can't decode password ! Here the code

        cmd.CommandText = "SELECT * FROM ps_employee WHERE email=@email AND passwd=MD5(@pwd) AND active=1"

As you can see, i'm using MYSQL MD5 function, but ... it not work.. Password is correct, i'm sure...


回答1:


The password hash is salted, prestashop seems to be using the value _COOKIE_KEY_ in settings.inc.php for this.

You will have to look up this value and compute the md5 hash of it and the password concatenated: md5(@COOKIE_KEY.@pwd)




回答2:


This is a security feature built into PrestaShop. You will not be able to decode any encoded passwords.



来源:https://stackoverflow.com/questions/5903170/prestashop-trying-to-decode-password

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!