Register now or log in to join your professional community.
Use AES_ENCRYPT (),AES_DECRYPT() functions in mysql for encryption and decryption.
example:
insert into landb.login (id, username, password )values(123, '12',AES_ENCRYPT ('nidhinek','nixpass'))
select AES_DECRYPT(landb.login.password, 'nixpass') from login where id=123
Output:nidhinek
There's a library from php for encryption which is php5_mcrypt. Try to read it in PHP documentation and it's very easy.
check the php library for encoding and decoding , all what you need to install the library on server and just call a php function ....i think you can add salt for the encribtion
Generally, reversible encryption functions (like AES_ENCRYPT and ENCODE) are deprecated since their attack as much easier than irreversible functions.
Try using irreversible function instead.Example
SHA1, MD5