YoVDO

MERN Stack Authentication with JWT Access, Refresh Tokens, Cookies

Offered By: Dave Gray via YouTube

Tags

Node.Js Courses React Courses Authorization Courses Web Application Security Courses JWT (JSON Web Tokens) Courses

Course Description

Overview

Learn to implement MERN Stack Authentication and Authorization using JWT Access & Refresh Tokens and secure cookies in this comprehensive video tutorial. Explore the creation of auth routes and an auth controller for a REST API that handles authentication and issues JWT tokens for valid users. Dive into topics such as rate limiting middleware, understanding the JWT auth process, creating token secrets with Node.js, and implementing login, refresh, and logout methods in the auth controller. Follow along as the instructor demonstrates how to create middleware to verify JWTs, apply it to routes, and test various endpoints using Postman. Gain valuable insights into building secure and robust authentication systems for your MERN stack applications.

Syllabus

Intro
Welcome
Quick lessons recap
Authentication vs Authorization
Starter Code
Add auth routes to server
Auth routes router
Rate limiting middleware
Auth controller
Adding controller methods to auth routes
Understanding the JWT auth process
Create token secrets with Node.js
login method in auth controller
refresh method in auth controller
logout method in auth controller
Create middleware to verify JWTs
Apply verifyJWT middleware to routes
Test the login endpoint with Postman
Test the refresh endpoint with Postman
Test the logout endpoint with Postman
Test the verifyJWT middleware with Postman


Taught by

Dave Gray

Related Courses

MongoDB for Node.js Developers
MongoDB University
Introduction to Office 365 Development and APIs
Microsoft via edX
Server-side Development with NodeJS
The Hong Kong University of Science and Technology via Coursera
Front-End Web UI Frameworks and Tools
The Hong Kong University of Science and Technology via Coursera
Introduction to MongoDB using the MEAN Stack
MongoDB via edX