Possible Duplicate:
MySQL password function
I am making tables for my homepage’s registration fields using MySQL.
I googled the way for encrypting passwords and it showed me that I can use password() on MySQL query for the encryption.
The problem is, when I change my database system like MySQL -> Oracle, can I migrate my database and the encrypted keys?
Is it okay that I use just password() without any worries?
Thanks in advance
ps. I apologize that I didn’t bring any source code but I don’t know even it will work or not.
No. Take a look at this question on how to store passwords in a DB. Basically you should used something like bcrypt to hash the passwords before storing them. These schemes are not only very secure, but are also DBMS-agnostic, so you don’t have to worry about any DBMS migration issues.