MediumConceptAuthentication and sessions end to end
How does a server-side session work with a cookie?
What a good answer covers
The server stores session data keyed by a random ID and sends the ID in a cookie. Each request includes the cookie, and the server looks up the session, so sessions can be revoked instantly.
PreviousPOC: build a small task-list app with an API, a database and a UINext What cookie attributes do you set for a session cookie?