Jump to content

How Secure Are Session Variables?


smerny
 Share

Recommended Posts

If I have a session variable "user_rank" and have a number assigned to it which determines whether or not the user has access to certain features.... is that secure? or should I be cross-checking the database every time a user does something that requires a high rank?

Link to comment
Share on other sites

If I have a session variable "user_rank" and have a number assigned to it which determines whether or not the user has access to certain features.... is that secure? or should I be cross-checking the database every time a user does something that requires a high rank?
I'd have their rank in the database. When the user enters a page, the session variable only needs to tell the PHP script that the user is logged in.EDIT: Actually, none of the session information except the ID is ever sent to the client, so the information of a session variable is pretty safe. Edited by Ingolme
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...