Most http web frameworks have session and cookie support built in. Sessions enable persisting user data across requests which allows features like login. In this class You'll learn how cookies are parsed, signed and implemented as middleware in most frameworks.
What's in this class?
Introduction: Session Cookies - Learn what will be covered in the class and tour the project.
Review of Cookies - Learn the basics of the Set-Cookie and Cookie headers.
Parsing Cookies - Parse a cookie string into an object we can work with.
Session Identifiers - Identify the user over time with a unique id stored as a cookie.
Storing Session Data - Serialize session data into a json string stored in the cookie.
Login and Logout - Use our new session store to implement basic login and logout systems.
Signing Cookies - Prevent users from tampering with cookies by signing them.
Session Middleware Example - See how session is typically implemented as http middleware.