Jump to content

Archived

This topic is now archived and is closed to further replies.

presence

Session security method

Recommended Posts

I'd like thoughts on how secure the following authentication method is after a login:

A user logs in successfully. Their user id is stored in a php session while their ip address and session id are entered into their user file in the database.  Whenever a user submits or form or tries to do anything important their submitted user id is looked up, and their ip address and session id are compared to the values stored for that user id in the database. If either don't match, the user is kicked back to the login screen.

As near as I can tell, this should be a good and secure method to deal with false user information being entered after login, but I'm just good enough at coding to know how inept I am at coding sensibly. :) So, is this a safe/efficient method?

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.