title: Secure Login PHP CodeIgniter
body: <p>I'm building the login part of a CodeIgniter app using the <a href="http://ttp://codeigniter.com/wiki/Simplelogin/" rel="nofollow">simple login class</a> as the starting point. It's all working fine, but I'm unsure of the differences between the encryption types, and which to use. </p>
  
  <p>I've gone for using the crypt() function with the user's password as the salt (via md5), like so: </p>
  
  <p><code>$pass == crypt($_POST['login_password'], md5($_POST['login_password']))</code></p>
  
  <p>Is this method ok, or is there a glaring error in that approach? This seems secure as neither password or salt are stored in the database. Or is it a bit obvious?</p>
  
  <p>Thanks in advance.</p>