I’ve read that storing login information in cookies is a security risk since they can easily be edited by the user. My question is if all I store is the username and password in the cookies then why is it risky? If I just made a simple authentication script to make sure the password and the username match up before retrieving information from the database why would this be risky? The user editing the cookies would still need to know the correct username and password that match together to gain access.
I am planning on doing this so users can stay logged in after the session ends.
I’ve read that storing login information in cookies is a security risk since they
Share
Well if you store the username and password in the cookies, then they will be accessible to anyone with access to the computer.
This wouldn’t be very secure.