Welcome Guest, Not a member yet? Register   Sign In
User Authentication - Placement of code?
#3

[eluser]RyanH[/eluser]
[quote author="dawnerd" date="1200962457"]You're doing it correct, however it's not very secure. Ideally you would store the session in a database and use unique hashes to check if the user is actually who they say they are.

To log the user out, just destroy the session.

Like I said before, basing it only off session id's is just asking to be hacked.[/quote]Thanks. I am actually storing the session information in the database, this was just an example. However, what would be a more secure way to check to see if the user is who they say they are?

Where would the code go to destroy the session?

Also, is there a way to modify the CI code to allow for the storing of custom information, such as usernames or what have you? The user guide says that you can use the information but upon reading the Wiki and searching the forums it appears that you can't, at least currently, store anything beyond the standard session information in the database.


Messages In This Thread
User Authentication - Placement of code? - by El Forum - 01-21-2008, 12:31 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 12:40 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 12:48 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 12:59 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 01:10 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 02:55 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 03:55 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 04:01 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 04:22 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 06:05 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 06:21 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 06:37 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 07:07 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 07:11 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 07:25 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 07:34 PM
User Authentication - Placement of code? - by El Forum - 01-21-2008, 08:01 PM
User Authentication - Placement of code? - by El Forum - 01-23-2008, 03:43 PM
User Authentication - Placement of code? - by El Forum - 01-23-2008, 05:42 PM
User Authentication - Placement of code? - by El Forum - 01-25-2008, 03:55 AM
User Authentication - Placement of code? - by El Forum - 01-25-2008, 08:58 AM
User Authentication - Placement of code? - by El Forum - 01-25-2008, 09:59 AM



Theme © iAndrew 2016 - Forum software by © MyBB