User Authentication in Web Apps (Passport.js, Node, Express)

  Рет қаралды 409,959

freeCodeCamp.org

freeCodeCamp.org

Күн бұрын

In this full course for beginners, you will learn how to implement user authentication from scratch in your web apps. You will learn how to use Passport.js in a Node / Express app.
💻 Starter Code
🔗 github.com/zachgoll/express-s...
🔗 github.com/zachgoll/express-j...
✏️ Course created by Zach Gollwitzer. Check out his channel: / zachgollwitzer
⭐️ Course Contents ⭐️
⌨️ (0:00:00) Introduction
⌨️ (0:04:04) Topics and Prerequisites
⌨️ (0:16:43) Intro to HTTP Headers and Cookies
⌨️ (0:34:23) Intro to Express Middleware
⌨️ (1:05:04) Intro to Express Sessions
⌨️ (1:31:10) Implementation of Passport Local Strategy
⌨️ (2:50:21) Intro to Public Key Cryptography
⌨️ (3:34:31) How do JWTs work?
⌨️ (4:16:58) Implementation of Passport JWT Strategy
⌨️ (5:17:29) Implementing a Custom JWT Auth Solution
⌨️ (5:46:20) JWT Strategy in Angular Front-End App
--
Learn to code for free and get a developer job: www.freecodecamp.org
Read hundreds of articles on programming: freecodecamp.org/news

Пікірлер: 316
@benjamincastro541
@benjamincastro541 2 жыл бұрын
Can't thank you enough for this tutorial. I have also watched several tutorials that have left me with more doubts than answers, so I appreciate how thorough this tutorial is. Amazing job!
@CodeShockDev
@CodeShockDev 3 жыл бұрын
To my name sake, this is really well done! I am a mid level node developer and found the steps and extra bits you gave to be outstanding and more then worth the time spent going through it. Well done sir!
@rajnori.
@rajnori. 2 жыл бұрын
Probably the best tutorial online for user authentication! Excellent delivery of the middleware concept with user authentication flow. @Zach Gollwitzer, you're a legend! Keep up the great work.
@theblackunderflow1842
@theblackunderflow1842 2 жыл бұрын
This tutorial is criminally underrated. Watched the whole way through. 10/10.
@bekiteshome4670
@bekiteshome4670 Жыл бұрын
yoo how is your full stack journey?
@theblackunderflow1842
@theblackunderflow1842 Жыл бұрын
@@bekiteshome4670 it is at a standstill my brotha, going back to school in the fall and hoping to snag internship opportunities from there.
@bekiteshome4670
@bekiteshome4670 Жыл бұрын
@@theblackunderflow1842 I hope you get what you want goodluck
@theblackunderflow1842
@theblackunderflow1842 Жыл бұрын
@@bekiteshome4670 thanks, good luck to you too!
@fattyboombatty7736
@fattyboombatty7736 2 жыл бұрын
Zach, one thing I really like about your videos is that you don't edit out the mistakes when you make them, but correct them in full view. I find this useful as it gives me the opportunity to think why something didn't work too. It is a really helpful learning aid (well for me it is).
@stevesmith0624
@stevesmith0624 7 ай бұрын
debugging is super important in programming too, it gives you an idea on how to debug your code for beginners out there
@EddyVinck
@EddyVinck 3 жыл бұрын
I watched this on Zach's channel first. For anyone wondering, it's absolutely worth to to follow the entire thing!
@yusufkolawole4291
@yusufkolawole4291 3 жыл бұрын
from twitter to youtube!
@joshuacushing2858
@joshuacushing2858 Жыл бұрын
I really appreciate your compassion and desire to make no assumptions in your descriptions. As a beginning developer, I have experienced exactly what you are talking about. Someone breezes through a concept, and I am left thinking, "Was that supposed to be straightforward?" Thank you so much for acknowledging how many complicated steps go into this process and helping to break it down.
@dochimekashiariri7610
@dochimekashiariri7610 2 жыл бұрын
this tutorial is not only helping me in user authentication but also in resolving the doubts I had about express js. HATS OFF to the instructor for making such a clear and precise tutorial.
@official.mhm13
@official.mhm13 3 жыл бұрын
Watched this complete tutorial and it was one of the best and comprehensive tutorial I have ever watched. Thanks Zach!
@christiankomodo
@christiankomodo 3 жыл бұрын
Your videos are great! Thorough and beginner-friendly but brings you through the whole thing. Perfect!
@ishehad8091
@ishehad8091 3 жыл бұрын
I ike the guy's tempo. A lot of youtubers try to keep videos short by talking really fast - to the point where it becomes impossible to follow and comprehend. This guy makes it just right - very easy and pleasant to listen. Good job!
@chadiusmaximus9350
@chadiusmaximus9350 3 жыл бұрын
Agreed
@EnLaMitad
@EnLaMitad 3 жыл бұрын
Definitely. When I hear someone talking about their "dense" content I immediately raise an eyebrow.
@hunl.919
@hunl.919 3 жыл бұрын
This cleared up so many of my questions as a starter especially on topics like cookies, sessions, and other accompanying middlewares. Bravo!
@justinfitzpatrick1074
@justinfitzpatrick1074 Жыл бұрын
This is a really phenomenal job of explaining this topic and helped me in my work immensely. The only video I've found that didn't talk over my head. Thank you Zach!
@keenanmolver9689
@keenanmolver9689 3 жыл бұрын
Finally a video where I don't feel like a parrot, just copying what they're typing trying to understand.
@minsupark9246
@minsupark9246 2 жыл бұрын
I wasn't the only parrot lol
@maxovicsteiner9646
@maxovicsteiner9646 2 жыл бұрын
you weren't the only parrot bruh
@shaocongshi2001
@shaocongshi2001 2 жыл бұрын
This is one of the best tutorials I have ever encountered! Thanks so much for your time and effort. I learned a lot.
@rikardcederberg2160
@rikardcederberg2160 2 жыл бұрын
Thank you for this really in depth tutorial. I would love to see more like this on other React and web development stuff. Keep up the good work.
@emcsquare62
@emcsquare62 3 жыл бұрын
Awesome class and instruction. Your teaching and examples have an easy to follow narrative and flow to them! Great job!
@ronnysusanto6755
@ronnysusanto6755 3 жыл бұрын
Great video! I love how in depth you go on certain topics and concepts! Thank you!
@cyberducc
@cyberducc Жыл бұрын
This is the most important tutorial I've ever seen about authentication. The topics presented in this video are invaluable to me and many other devs. Thank you so much Zach. I will refer this tutorial to anyone wanting to learn authentication in nodejs apps. 🚀
@tylerdurden2832
@tylerdurden2832 3 жыл бұрын
I was waiting for this for yearssssss man.
@baderidrees
@baderidrees 4 ай бұрын
That was full of information, especially the distigush of hashing and encryption, I watched the whole 6 hours of it. 🙂🙂
@Jp_codes
@Jp_codes 3 жыл бұрын
Zach. you are a blessing. where have you been? ten minutes into the video and am already feeling great...
@timfranklin4724
@timfranklin4724 Жыл бұрын
Finally! This is what I've been looking for for months. Like you said in the video, it's always "learn authentication in 5 minutes".
@delektowski
@delektowski Жыл бұрын
Great middleware explanation! Thank you! :-) I am continuing to watch that further!
@destroyer40869
@destroyer40869 3 жыл бұрын
Special thanks to Zach and FCC for this awesome tutorial. Really learned a lot from this tutorial. Keep coming with these type of tutorials :))
@arpitanand6534
@arpitanand6534 3 жыл бұрын
Man!! You have taken care of and have explained every other aspect of what you wrote in the code!! This is just amazing. ❤
@krobi26
@krobi26 2 жыл бұрын
thank you! This was great! I had watched a few quick tutorials elsewhere but had no idea why I was copying and pasting all the stuff they prescribed. This gave me an actual understanding of what everything is doing.
@aminarahman2429
@aminarahman2429 Жыл бұрын
I have coded along up-to Express MIddlewares so far, never have these concepts been clearer than it is now after watching your video. Thanks a lot!!
@jDelestal94
@jDelestal94 7 ай бұрын
Zach , thanks for your job, you are a great professional ! , I panicked when I started with advanced node js on the curriculum of fcc, and with this course i am learning the basic to continue. Thanks. grettings from argentina
@dragosgeorge1086
@dragosgeorge1086 3 жыл бұрын
I can't believe how good this tutorial is. Thank you so much!
@MrMagicPenguin12
@MrMagicPenguin12 2 жыл бұрын
Extremely thorough, worth the time for any beginner!!
@wurblyy
@wurblyy Жыл бұрын
Thank you so much for being so clear and going further to explain the whys in your tutorial. This was amazing, thanks Zach!
@gavinwatson4549
@gavinwatson4549 Жыл бұрын
The video helped me a lot to understand authentication with passport, jwt, session-express and many other things, really thank you very much :')
@delektowski
@delektowski Жыл бұрын
Your deep understanding of what you didn't understand made that tutorial easy to understand! :-) Thank you.!
@audraogilvy2605
@audraogilvy2605 2 жыл бұрын
Thank you very much for teaching so conscientiously. It was obvious you cared that people who are trying to learn will understand. I watched someone else's video and he went so fast and didn't explain a lot, and that can get frustrating and discouraging. It's so nice that you guide us at a proper pace for students.
@user-iz2ge2fl4x
@user-iz2ge2fl4x 2 ай бұрын
Thanks, that was amazing! The instructor teaches concepts of authentication, how to implement without abstraction and how tech like passport.js actually works under the hood.
@geebsayshi
@geebsayshi 2 жыл бұрын
This is a goldmine. Learned a lot. Can't thank you enough Zach and FCC.
@justcreate1387
@justcreate1387 Жыл бұрын
I haven’t completed the video yet. But I must say..thank you for being such a clear and concise teacher!
@ivank.2040
@ivank.2040 2 жыл бұрын
This is a really really amazing tutorial! You have so clear explanation, thanks a lot!
@chinwenduenyinna9018
@chinwenduenyinna9018 Жыл бұрын
Thank you Zach for this tutorial! You simplified the concept of authentication and I found it really helpful.
@pranit_7D
@pranit_7D 3 жыл бұрын
Amazing! I was just looking for this
@zeldris6218
@zeldris6218 3 жыл бұрын
Amazing , thats all I was looking for 🔥🔥
@mack2386
@mack2386 7 ай бұрын
Thank you, sir! I was having a ton of trouble wrapping my head around Passport before your videos. Now it feels familiar and less daunting. Much obliged
@mateovivas6920
@mateovivas6920 3 жыл бұрын
Watched 6 hours in 2x speed and still could get the whole thing. Pretty good explanation.
@VishalGupta-dn4td
@VishalGupta-dn4td 2 жыл бұрын
Amazing tutorial, it actually helps me to understand what is going on under the hood rather than just copy pasting the code.
@shivkumarsingh5315
@shivkumarsingh5315 2 жыл бұрын
You are the best! So many doubts, all resolved in just one video. Thank you so much!
@Wilespro1
@Wilespro1 3 жыл бұрын
You are the best! It is clear that you want people to really understand things. Thanks for making this video!
@chadiusmaximus9350
@chadiusmaximus9350 3 жыл бұрын
My next day off I am going to consume this whole video. Thank you.
@mpowers3311
@mpowers3311 3 жыл бұрын
great! worth to follow this man. Great teacher I have ever watched .
@TechReagan
@TechReagan 3 жыл бұрын
This is awesome, thanks for sharing. I will watch till the end.
@Picklin
@Picklin 2 жыл бұрын
Thanks so much for this video! Very clear and impact my understanding about middlewares/sessions working.
@chandisannidhanam4440
@chandisannidhanam4440 2 жыл бұрын
Thanks ! Zach for the great tutorial ! it's really awesome course on the User Authentication ! All 6 :13 hours is really worth, loaded with full of information , which I can really apply .
@dijiflex
@dijiflex 3 жыл бұрын
Good work. The first section on middleware was a good refresher for me especially on the error handling part
@NAYY_STUDIOS
@NAYY_STUDIOS 5 ай бұрын
First authentication video and I am confident will master it soon. Thanks Zach
@nirmal_kumar
@nirmal_kumar 3 жыл бұрын
Excellent Tutorial to understand not just Authentication but also the Fundamentals of Cryptography with JWT
@abdurrahimahmadov4309
@abdurrahimahmadov4309 2 жыл бұрын
Thank you for this amazing course! This course and FCC QA curriculum helped me a lot to understand the passport framework.
@rupertxyz
@rupertxyz Жыл бұрын
Amazing tutorial which isn't skipping over too many parts!
@sayidmuhammad443
@sayidmuhammad443 3 жыл бұрын
I love this guy he is an amazing teacher
@gurucharan769
@gurucharan769 3 жыл бұрын
by far, the best course on authentication
@rjwhite4424
@rjwhite4424 7 ай бұрын
fantastic video. Spent an entire work day watching this video and it was well worth it!
@stevesmith0624
@stevesmith0624 7 ай бұрын
very well organized and explained course, thanks guys for putting out another banger
@DjokovicAirlines
@DjokovicAirlines 3 жыл бұрын
Thanks for JWT Strategy in Angular. That was super useful!
@vedantchaudhari2672
@vedantchaudhari2672 4 ай бұрын
Really nice explanation. Simple yet crucial.
@alializadeh4542
@alializadeh4542 3 жыл бұрын
Thank you I was waiting for this course
@-seoulair
@-seoulair Жыл бұрын
I have a feeling this is gonna be great. Can't wait to finally understand session and jwt
@mohithadiyal6083
@mohithadiyal6083 3 жыл бұрын
This channel is something I recommend to every one.
@amirsaad8627
@amirsaad8627 3 жыл бұрын
thank you Zach this really boost me forward to understand how this working after long time stuck and disappointed about auth subject. thank you :)
@contentshark5122
@contentshark5122 2 жыл бұрын
Such an amazing explanation !! Thanks a million !! Even just for one sec I didn't feel like I am struggling to understand...
@madhurmongia6381
@madhurmongia6381 3 жыл бұрын
first of all introduction got hooked me up like the guy read my mind i was using firebase for authentication but i think now i am ready for my owm backend.
@md.siddiq7165
@md.siddiq7165 3 жыл бұрын
I watched this series few days ago. The series is just awesome & perfect for beginners.
@ogunsadebenjaminadeiyin2729
@ogunsadebenjaminadeiyin2729 3 жыл бұрын
Please can you describe what this series is about, for a novice?
@md.siddiq7165
@md.siddiq7165 3 жыл бұрын
@@ogunsadebenjaminadeiyin2729 Websites that we visit has a signup, sign In functionality which helps to authenticate the user. The series is about authentication and also authorization. It is one of the basic things in backend development. Hope you got your answer
@panomapet9441
@panomapet9441 3 жыл бұрын
where is the series/playlist?
@md.siddiq7165
@md.siddiq7165 3 жыл бұрын
@@panomapet9441 actually Zach has his own youtube channel & he uploaded this whole 6hr long video as a series in his channel.
@panomapet9441
@panomapet9441 3 жыл бұрын
@@md.siddiq7165 I got his channel. Thanks
@rohitsrao
@rohitsrao 2 жыл бұрын
This was brilliant. Thanks a TON for sharing it.
@jackpaulcollins
@jackpaulcollins 3 жыл бұрын
Came for Passport, stayed for the great explanation of middleware
@ochinuengsriphiphat2427
@ochinuengsriphiphat2427 3 жыл бұрын
Hi Zach thank you for a great tutorial! btw I notice in JWT part at 5:07:55 you already authenticate user with login endpoint and already signed token that's mean user authenticated so why you authenticate again in JWTStretagy with user.findOne? that mean database have to query every time when JWTStrategy called to authenticate user, is it break the JWT steteless mechanism ?
@SunilVGandhi
@SunilVGandhi Жыл бұрын
Nice, precise and concise. I am enlightened 👌
@LetsGeTDeep
@LetsGeTDeep 2 жыл бұрын
If you are on the fence about this tutorial, watch it until at least the passport section ends. Phenomenal lesson.
@filix6360
@filix6360 7 ай бұрын
Very informative...keep at it man!.
@hemantvardani1436
@hemantvardani1436 Ай бұрын
Thanks!! for this beautiful video :)
@ayushshaw3681
@ayushshaw3681 2 жыл бұрын
This video was a savior for me. I was facing the exact same problems which you mentioned in the beginning.
@dreamer5632
@dreamer5632 Жыл бұрын
thank you so much Zach you explained so many things so simply thanks a lot
@sumprj
@sumprj 2 жыл бұрын
Thank you for your efforts. Sharing knowledge is easy but delivering in such a way that everyone can understand is very much difficult. We need a hell a lot of preparation for that. Hats off to your efforts.
@tarasgolyk6525
@tarasgolyk6525 3 жыл бұрын
Perfectly! But I would watch all 10 hours of video if there was a continuation about the refresh token 😉
@alexhein5248
@alexhein5248 Жыл бұрын
This tutorial clear the confusion out of me about authentication and how cookies work
@jon1867
@jon1867 Жыл бұрын
This video is phenomenal! Great Work
@sameershahbaz8821
@sameershahbaz8821 Жыл бұрын
big fan of your teaching method sir, clear and concise with great detail...hoping you to get more exposure among people so that they can learn from you, please release reactjs course I really wanna learn from you, because I have been scratching my head with so many tutorials on youtube and didnt get help. thank you sir
@punisherash388
@punisherash388 Жыл бұрын
This is a great video, not because it did what it has to, but because it amde you familiar with options, what else and etc. nice content.
@Samsul2013
@Samsul2013 3 жыл бұрын
superb and speechless ...explanation crystal clear
@muxammad2777
@muxammad2777 3 жыл бұрын
I don't know what to say, thank you very much you are awesome man
@josbexerr5166
@josbexerr5166 2 жыл бұрын
Muchas Gracias Mister Zach, por una gran Catedra......saludos de los andes Peruanos
@toihirhalim
@toihirhalim 3 жыл бұрын
the course I didn't know I need
@ndahayokevin7626
@ndahayokevin7626 Жыл бұрын
Amazing, Now I am going to develop strong backend applications.
@ccaiuss
@ccaiuss 2 жыл бұрын
wow man ! the best tutorial ! you are the best !!!
@samuelrajdev3412
@samuelrajdev3412 4 ай бұрын
Wonderful!!
@shidro9450
@shidro9450 2 жыл бұрын
Thank you for this video its been very helpful one!
@sanskaarpatni9137
@sanskaarpatni9137 3 жыл бұрын
Thanks a lot Zach!
@matinotsaintilus4124
@matinotsaintilus4124 3 жыл бұрын
Great work... Tuto on fire
@Killow
@Killow 3 жыл бұрын
Very great content, high quality tyou !
@bloodzz4813
@bloodzz4813 3 жыл бұрын
A really good tutorial, so if anyone is watching it rn, I would like to explain some stuff you need to know, 1. don't use the way he uses connect-mongo bc I struggled doing it like him, that's bc this tutorial is a bit outdated, there is a new way of using connect-mongo , look at the docs for it... 2. Once you get to the local strategy it will feel a bit overwhelming so I recommend installing and work and code along, generally look for another tutorial then look for his tutorial at that part just to understand some stuff he goes throw quickly, like hast, salt, etc. That's what I did myself.
@lewiduressa
@lewiduressa 11 ай бұрын
This is literally the best video!!
@abhinavsingh-zc2hk
@abhinavsingh-zc2hk 3 жыл бұрын
Best tutorial ever on auth 🧡🧡🧡
@shamkhall
@shamkhall Жыл бұрын
thank you very much. it is a very helpful lesson.
Difference between cookies, session and tokens
11:53
Valentin Despa
Рет қаралды 594 М.
God-Tier Developer Roadmap
16:42
Fireship
Рет қаралды 7 МЛН
WHO DO I LOVE MOST?
00:22
dednahype
Рет қаралды 82 МЛН
That's how money comes into our family
00:14
Mamasoboliha
Рет қаралды 6 МЛН
HOW DID HE WIN? 😱
00:33
Topper Guild
Рет қаралды 27 МЛН
ОСКАР vs БАДАБУМЧИК БОЙ!  УВЕЗЛИ на СКОРОЙ!
13:45
Бадабумчик
Рет қаралды 2,6 МЛН
What Is JWT and Why Should You Use JWT
14:53
Web Dev Simplified
Рет қаралды 1,1 МЛН
Express JS #15 - Passport.js Authentication
37:41
Anson the Developer
Рет қаралды 9 М.
Session vs Token Authentication in 100 Seconds
2:18
Fireship
Рет қаралды 1 МЛН
How I’d learn ML in 2024 (if I could start over)
7:05
Boris Meinardus
Рет қаралды 964 М.
Learn Express JS In 35 Minutes
36:03
Web Dev Simplified
Рет қаралды 765 М.
Java for the Haters in 100 Seconds
2:22
Fireship
Рет қаралды 2,7 МЛН
Every React Concept Explained in 12 Minutes
11:53
Code Bootcamp
Рет қаралды 444 М.
Using My Python Skills To Punish Credit Card Scammers
7:13
Engineer Man
Рет қаралды 4,8 МЛН
WHO DO I LOVE MOST?
00:22
dednahype
Рет қаралды 82 МЛН