• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Freakauth_light recoded + remember me functionality

#1
[eluser]James McMurray[/eluser]
I recently found the version of freakauth_light recoded to work with CI 1.7+ and like it a lot, but it doesn't have any remember me functionality. So I added it. Smile

The attached zip has the only the files needed to convert that version of freakauth_light to use the remember me functionality. Copy them over the original FreakAuth Light Recoded files and run user_persistence.sql to enabled Remember Me functionality.

The full FreakAuth Light Recoded + Remember Me is too large to attach to the forums. It can be downloaded here. In it are instructions for installation (installation_instructions.txt) and instructions for enabling remember me functionality (Enabling User Persistence.txt).


The basic flow of User Persistence and the changes that were made:
1) autoload the user_persistence library
2) add a parameter to login() to let us know if it's a forced login due to a cookie error so the user can be told.
3) move the random string generation to a helper so it can be used for the cookies
4) add an error message to display when there is a cookie sync problem
5) add a remember me checkbox to the login form
6) if the box is checked at login, persist the user
7) erase their persistence at logout
8) cookie creation / processing is handled as described in bjaspan's Improved Persistent Login Cookie Best Practice. While it might not be perfectly secure (remember me can't be), this functionality is not intended for ecommerce, so it should be good enough.


Messages In This Thread
Freakauth_light recoded + remember me functionality - by El Forum - 08-18-2010, 10:47 AM
Freakauth_light recoded + remember me functionality - by El Forum - 08-19-2010, 01:31 PM
Freakauth_light recoded + remember me functionality - by El Forum - 08-19-2010, 01:40 PM
Freakauth_light recoded + remember me functionality - by El Forum - 08-20-2010, 10:20 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.