Understanding Authentication in Node.js - Sessions and Cookies - Web Development Concepts Explained

Поделиться
HTML-код
  • Опубликовано: 29 янв 2025

Комментарии • 290

  • @the_full_stack_junkie
    @the_full_stack_junkie  4 года назад +38

    GitHub Repo for the project code in the video 🤓:
    github.com/LloydJanseVanRensburg/Authentication_Node_Sessions_Cookies
    Hope you liked this video. In the next authentication video I will be handling authentication from a API using JWT check it out in the web development concepts explained playlist!
    Have a great day peace out...

    • @engespress
      @engespress 3 года назад

      Good tutorial. Thanks!

    • @elyasarkin0991
      @elyasarkin0991 2 года назад +1

      Awesome and clean tutorial thank you

    • @mushfiqurniaz_
      @mushfiqurniaz_ 4 месяца назад

      I was about to comment if you don't put in source code you're gay but thanks

  • @jesusenriqueperez5307
    @jesusenriqueperez5307 3 года назад +45

    I've watched many videos about express-session and you are the first person that explains what is that cookie's purpose. Thank you

    • @the_full_stack_junkie
      @the_full_stack_junkie  3 года назад +6

      Thanks so much very glad it helped champ

    • @sameerswankar
      @sameerswankar Год назад

      what happens when i open two tabs and login from different account on each of them, will the cookie gets overwritten ? How will that work

  • @emilejuniorada6670
    @emilejuniorada6670 3 года назад +24

    48hours. I've been struggling to understand those sessions things for 48 hours, making my ways through bunch of tutorials, and you just saved me. more follower

  • @claudiovitordantas2348
    @claudiovitordantas2348 3 года назад +2

    man, this is the best video on how to do a simple authentication on nodejs! congrats!!

  • @blackpeep984
    @blackpeep984 Год назад +1

    Holy shit bro this gotta be the best, easiest and most straightforward tutorial on sessions. Thank you very much!

  • @muhammadjunaid3684
    @muhammadjunaid3684 3 года назад +18

    What an amazing tutorial!
    I couldn't learn about sessions without this tutorial.
    Really love that 😍😍😍

  • @slimshady9733
    @slimshady9733 3 года назад +2

    Arguably the best video on login session .. tried many places but this is the only place I truly understood

  • @dilmurod9820
    @dilmurod9820 4 года назад +3

    Best Teacher i have ever seen in programming on youtube respect

  • @florin1335
    @florin1335 4 года назад +7

    Bro, I watched a few tutorials on this topic but yours was the best.

  • @unessss
    @unessss 3 года назад +5

    I highly recommend this video to beginners... He explained EVERY line and word and code as simple as they could be...
    wish he covered the OAuth tho (like google login or other authenticating platforms )

  • @walideker2253
    @walideker2253 11 месяцев назад +2

    bruh tysm i hve been strugling over 2 weeks only ur video did it
    tysm

  • @xanderav
    @xanderav 3 года назад +2

    As others have said I also watched many videos about this but this is THE BEST, it's just so clean, straightforward, it's amazing, thanks!

  • @franciscosalazar8116
    @franciscosalazar8116 Год назад +1

    Wow, this video is amazing!!!!!Thanks so much it wouldn't have been possible to understand this without your video!!! I could deploy my app finally thanks to you!!!

  • @hand-somepaws9285
    @hand-somepaws9285 3 года назад +2

    Perfectly explained. More information given. This is the best video I ever searched for.

  • @Abhisheky418
    @Abhisheky418 3 года назад +10

    This was so clean , precise and to the point just loved it. thankyou for making this.

  • @TommyMN
    @TommyMN Год назад +1

    Thank you so much, I was searching the web for a good understanding of these subjects and you explained them very well my friend!

  • @iganic7574
    @iganic7574 Год назад +2

    This is surely the easiest video about authontication 😍. Thanks bro your are amazing

    • @sameerswankar
      @sameerswankar Год назад

      what happens when i open two tabs and login from different account on each of them, will the cookie gets overwritten ? How will that work

  • @fatimaarshad8100
    @fatimaarshad8100 Год назад +1

    I'm really thankful that you solve my problem I was stuck like from 2 days and I don't get it why my session and passport auth not working. Your method of teaching is more calm and understandable. I'm really thankful to you

  • @harshad1704
    @harshad1704 3 года назад +2

    one of the clear video on the express session very very thank you Junkie

  • @nagato6819
    @nagato6819 3 года назад +1

    omg!! finally, I found a good video about authentication, thank you for this great explanation

  • @harrisonvijay8897
    @harrisonvijay8897 3 года назад +3

    Thanks a lot for this video. It helped me, a beginner, understand cookies and sessions. Keep on posting!

  • @BaranivskyVadim
    @BaranivskyVadim 3 года назад +1

    Yes I agree. Very good explanation. I watched many videos, only this made my work finished

  • @PradeepKumar-fh2vs
    @PradeepKumar-fh2vs 3 года назад +1

    I have watched many videos but did not get clear picture of how the session is working. your video has cleared my lots of doubts, Thanks for such a wonderful tutorial.

  • @vipinr8473
    @vipinr8473 Год назад

    Thankyou for giving this wonderfull class thankyou so much

  • @brysonmrivera9153
    @brysonmrivera9153 3 года назад

    Definitely wish I clicked this video first aha. This is exactly what I needed to help me understand what is going on with sessions. Great stuff!!

  • @facundoloto1514
    @facundoloto1514 3 года назад +2

    this video help me understand the seccions and the cookies of login and logout,after hours and days search ,thanks so much

  • @sidheart8905
    @sidheart8905 2 года назад +1

    thank you very great and informative video... people are just tend to sue lot of addons or libraries , but from your video we can understand basic fundalmentals of authentication in nodejs using simple cookies and a database.

  • @felakos1568
    @felakos1568 3 года назад +3

    Very useful lesson and accessible presentation. Congratulations,
    you surpassed the whole Internet. Thank you sir.

  • @abeercodes
    @abeercodes 2 года назад

    why the hell haven't I watched your vids. you made it crystal clear

  • @Eddie4k
    @Eddie4k 2 года назад +1

    Wow best video I have found tbh on this topic

  • @adeyemodavidsunday7140
    @adeyemodavidsunday7140 Год назад

    Thank you so much for this wonderful piece I have been looking for a simplified authentication tutorial for so long but could not get one. I was able to follow your steps to implement AUTH using PostgreSQL database. Thanks a million times.

  • @__peanut__butter28
    @__peanut__butter28 3 года назад +4

    this video simplified the cookie session, thanks a lot live more!

  • @GustavoSilva-hh8or
    @GustavoSilva-hh8or 2 года назад

    I don't speak English, but thanks. You saved my life. I was looking for a tutorial for weeks and none of them helped me...

  • @mohdshoaib7622
    @mohdshoaib7622 Год назад +1

    Best video on express session authentication.

  • @duggie3026
    @duggie3026 3 года назад +1

    Thank you so much for the video. Your video helped me so much with the login and logout section.

  • @SanjuKumar-ye8xz
    @SanjuKumar-ye8xz 3 года назад +1

    Very simply explanation. Thank dude☺️☺️☺️

  • @akinwekomitemitope4748
    @akinwekomitemitope4748 Год назад +1

    this is soooo simplified. its like some authentication and authorization courses🥰🥰🥰🥰🥰

    • @the_full_stack_junkie
      @the_full_stack_junkie  Год назад

      So glad you found it helpful 🤓

    • @adeyemodavidsunday7140
      @adeyemodavidsunday7140 Год назад

      Thank you so much for this wonderful piece I have been looking for a simplified authentication tutorial for so long but could not get one. I was able to follow your steps to implement AUTH using PostgreSQL database. Thanks a million times.

  • @blank2782
    @blank2782 3 года назад +3

    Amazing, clearly explained everything. Thankyou so much for this video.

  • @GameDownloader112
    @GameDownloader112 3 года назад +1

    in 30min you explained better than teachers in 3 hour

    • @the_full_stack_junkie
      @the_full_stack_junkie  3 года назад +1

      Thanks champ, let me know of any topics you want explained and I will see what I can do

  • @yehudahimelfarb5935
    @yehudahimelfarb5935 2 года назад +2

    wow...excelent explication !!! 👏

  • @GaBlack-wo9vx
    @GaBlack-wo9vx 9 месяцев назад +1

    This video is really helpful, thank you so much

  • @PIXYBoy79
    @PIXYBoy79 3 года назад +1

    Nice tuts my South African friend. I like the context you provide. Keep it going

  • @ivantrachuk3736
    @ivantrachuk3736 2 года назад +1

    Omg dude, thank you so much, it's so clear and easy to understand!

  • @mohammadhossein9230
    @mohammadhossein9230 2 года назад +1

    This video was so helpful for me, thanks a lot

  • @VijayTamada
    @VijayTamada Год назад +1

    Nice & to the point! Great!!

  • @balajeemishra
    @balajeemishra 3 года назад +1

    Thank you sir. It was very useful. Today I understood what cookies actually do.

  • @nabeelhassan25
    @nabeelhassan25 10 месяцев назад

    Man this is great been wanting to learn about this for a while!

  • @medinatechalgeria1064
    @medinatechalgeria1064 2 года назад

    thank you thank you thank you !!! the best video un found about express-session i found on youtube !

  • @giddyvibes-0423
    @giddyvibes-0423 Год назад +1

    Am the type that really found it hard to understand but this video is solid Gold

  • @pankajmishra3559
    @pankajmishra3559 3 года назад +1

    i love your teaching style.
    thanks

  • @araj51149
    @araj51149 2 года назад +1

    The explanation is very clear

  • @niteeshmahato1596
    @niteeshmahato1596 2 года назад +1

    Very clean and to the point explanation. Loved it!

  • @GeraltOfArabia
    @GeraltOfArabia 3 года назад +1

    A well structured video. Thank you for explaining how cookies function.

  • @gamer-tech7568
    @gamer-tech7568 3 года назад

    Thanks very much your explanation was very clear and I understood very well , continue like this

  • @quanduong3390
    @quanduong3390 2 года назад +1

    Thank you so much for making this. You explained it well. Thank you

  • @rules654
    @rules654 3 года назад +1

    great work made, helped in my project.

  • @VaibhavC-co1bi
    @VaibhavC-co1bi 10 месяцев назад

    thank you man your lecture really helped me solving my issue

  • @kevingardner2236
    @kevingardner2236 2 года назад

    Learn by doing this! Posted from command line great video

  • @xosound5938
    @xosound5938 3 года назад +2

    Nice tutorial man!!! You really explained everything so well. Thanks 😊

  • @bariswheel
    @bariswheel 3 года назад

    I hope yo continue to make these videos, you have a gift!

  • @ravipayasi6875
    @ravipayasi6875 2 года назад +1

    Amazing explanation, liked and subbed

  • @huetemaier2499
    @huetemaier2499 3 года назад +1

    You made it very easy to understand! TY!

  • @nicogarcia7302
    @nicogarcia7302 3 года назад +1

    Soo good, your tutorials are lit mate💯, subscribed !!

  • @Jadestonk
    @Jadestonk 4 года назад +5

    outstanding tutorial man, thanks so much I learned a lot

  • @jamaScript
    @jamaScript 3 года назад +1

    Crystal clear. Thanks for this episode.

  • @souravvashisht7153
    @souravvashisht7153 2 года назад +1

    Thank you very Much.

  • @kevinwilliams6070
    @kevinwilliams6070 2 года назад +1

    Thank you so much. You explained this really well.

  • @shivangchaturvedi237
    @shivangchaturvedi237 3 года назад +1

    Amazing! Thanks you so very much. In my opinion, only 7 people didn't pay much attention to what you have explained and have ignorantly disliked your video, when in reality, there is absolutely nothing to dislike about this video. Loved your explanation and implementation

  • @mohammedjoubba318
    @mohammedjoubba318 3 года назад +2

    thank you , awesome explanation

  • @vishalkumar-th4gz
    @vishalkumar-th4gz 3 года назад +1

    very nicely explained helped a lot

  • @carlsagan9808
    @carlsagan9808 2 года назад +1

    Great sessions tutorial!

  • @manishbhardwaj4587
    @manishbhardwaj4587 Год назад +1

    love it, thank you Teacher!

  • @magdyismail946
    @magdyismail946 2 года назад +1

    Thank you
    This was very useful for me

  • @supriyasingh9818
    @supriyasingh9818 3 года назад +1

    Its really good and straightforward video.

  • @jamiroquaiordie
    @jamiroquaiordie 2 года назад

    thank you, finally understood how this works

  • @tekken1935
    @tekken1935 3 года назад +1

    Great job, very easy to understand and follow along

  • @indianafootballer3257
    @indianafootballer3257 3 года назад +2

    thank you... so understandable.. best taught ❤️❤️

  • @ebraamwadee2216
    @ebraamwadee2216 3 года назад +1

    just awesome it helped me alot and the explanation is very good and simple

  • @rayzecor
    @rayzecor 3 года назад +1

    This video was immensely helpful. Thank you very much.

    • @the_full_stack_junkie
      @the_full_stack_junkie  3 года назад

      So glad you found it helpful any other topics you have in mind?

    • @rayzecor
      @rayzecor 3 года назад +1

      @@the_full_stack_junkie Personally I am working on a MERN stack application currently with a websocket API and authentication, which is why I needed this video. I think it could be helpful to at least gloss over upgrading connections or other websocket related things?

    • @the_full_stack_junkie
      @the_full_stack_junkie  3 года назад

      Sounds interesting are you using socket.io or pure websocket?

    • @rayzecor
      @rayzecor 3 года назад

      @@the_full_stack_junkie Pure websocket. I believe socket.io takes care of most of the pains of ws, but I've not yet tried using it.

    • @rayzecor
      @rayzecor 3 года назад

      @@the_full_stack_junkie Actually, I have just run into an issue. After following your tutorial I have started working on a small project using a similar backend to this. The problem I was having is that my front and backend were separate and so I did not have access to the session, meaning if I refreshed the page I would have to relog. Could you make a video on how to deal with this? The one idea I had was to use a library to persist the redux store and remain logged in.
      EDIT: I have figured out how to do this, if anyone is interested you can find it here github.com/RaresGeo/mern-calendar-back/blob/10b70759b78556939e46dc98ddf3b67d1bb800ff/controllers/authController.js#L30
      You can also look at the frontend repo to see how I attempt login on page load (useEffect with empty dependancy array in App.tsx)
      I also ran into a bit of difficulties with cors, including the cookie in my request and just generally having a few issues with express-session, for example creating a new session on each login rather than using the same one.

  • @rajesht9694
    @rajesht9694 Год назад +1

    Wonderful demo

  • @soulxpZA
    @soulxpZA 4 года назад +1

    Ek wil sommer vir jou 'n dop koop. Dankie man.

  • @0xyz
    @0xyz 3 года назад +1

    Great Video, Thanks for this

  • @danielEpifanov
    @danielEpifanov 3 года назад +1

    wow, amazing content

  • @codefork94
    @codefork94 2 года назад +1

    Dude!!!! I finally get it!!!!

  • @sukhmanpreetsinghsandhub2042
    @sukhmanpreetsinghsandhub2042 Год назад +1

    Awesome video🙌

  • @iampatelajeet
    @iampatelajeet 2 года назад +1

    Just loved your explanation dude, everything so precise, you saved me, I'm already late for college projects submission...
    I also need to pass user data when signed in but understood the core concepts, thanks again.❤️❤️

  • @哈里森-y9l
    @哈里森-y9l 3 года назад +1

    Nice Share , thanks my bro , it's pretty worth for me !

  • @kevingardner2236
    @kevingardner2236 2 года назад

    Learn by doing this! Great Vid

  • @sundial_dream
    @sundial_dream Год назад +1

    Best explanation !! thank u so much

  • @drupalguy
    @drupalguy 2 года назад +1

    Good tutorial. Thank you

  • @mohamadabdeen6906
    @mohamadabdeen6906 Год назад +1

    great video ,thanks very much

  • @vikram87in
    @vikram87in 2 года назад +1

    great video... thanks 😍

  • @ayomichaels1204
    @ayomichaels1204 2 года назад +1

    This is super helpful

  • @nimahashemi7673
    @nimahashemi7673 3 года назад +1

    thank you bro! the best tutorial for auth

  • @ajwadmajed3551
    @ajwadmajed3551 2 года назад +1

    quick question.. do we need a fetch() API method to send the post request correctly? or is it correct to just use this tutorial ?

  • @hos7012
    @hos7012 2 года назад +1

    best explanation

  • @turtleanimationstudio8070
    @turtleanimationstudio8070 Год назад

    Love your lessons ,thanks alot

  • @cseedrvr6627
    @cseedrvr6627 4 года назад +1

    you explain very well man. keep it up.

  • @ashfaquemamdu4582
    @ashfaquemamdu4582 3 года назад +1

    Thanks man it was helpful

  • @johnore549
    @johnore549 3 года назад +1

    素晴らしいビデオ🥺🥺 君に出会えて良かったー😭