简体   繁体   中英

How can I protect password on PHP Symfony form

I have simple sign in form in my project on PHP Symfony. But I found this problem.

when I will use this command

$("#signin_password").val()

in Chrome it shows me password not secured.

How can I to protect user password in this way?

The best idea is to never show a raw password on the page. What's more, you should never store a raw password in a database or in any other medium.

The best method is to use one-way encryption to store all passwords, and in order to check a password, you would simply compare the "encypted string" to what is stored in the database.

Because you are using symfony 1.4, I'd suggest checking out the sfGuardPlugin for a ready-made solution.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM