Can anyone help me out to find the best encryption method for codeigniter?
-
why dont you use md5 or sha1 of php. They can be used in Codeigniter – Muhammad Raheel Jan 15 '13 at 6:50
-
@Raheel: md5 is not secure. It can be cracked – Sreehari Jan 15 '13 at 7:02
hi you can use md5 php function to encryt password string while login you have to check hash of string with hash saved in database there is one good post for password encryption you can read that
here are two good libraries for creating encrypted password
codeigniter auth library like tank auth using PHPass for encrypting password
-
Do not use MD5 for password hashing; md5 is now (or should be) officially useless for this purpose. – gedq May 16 '15 at 22:27
In few months a new php password API will be available.
https://gist.github.com/3707231
Its greatest advantage is that it hugely simplifies existing hashing APIs while still maintaining a high level of security.
Use password_compat from github.
Implements the new PHP 5.5 password hasing logic but you can use it now for older PHP versions
Link: GITHUB PASSWORD_COMPAT