Member-only story
Cookies and Session
My perception:
A memory function on the web browser side that remembers what you have done when you access a web server.
What is a Cookie?
A cookie is an extension of the HTTP specification that allows information to be exchanged between a web application and a web browser.
Information (cookies) made up of a combination of “name = value” is sent from the webserver to the web browser using the HTTP response header.
A cookie is a piece of information stored in a web browser (client).
When a web browser receives a cookie from a web server, the next time it accesses the same web server, it sends the received cookie as is in the HTTP request header.
The state of the client-side (Web browser) is maintained based on the cookie information.
Problems with Cookies
Cookies are not secure because they can be easily peeked at by using certain tools!
Therefore, as a way to keep more information more safely, a mechanism called “Session” was devised
How does a session work?
- A user uses a web browser to access a web server.
- The web server issues a session ID and associates it with…