JWT Authentication with .NET 9 🚀 Full Course with Roles, JSON Web Tokens & Refresh Tokens

แชร์
ฝัง
  • เผยแพร่เมื่อ 11 ก.พ. 2025

ความคิดเห็น •

  • @Ruler_034
    @Ruler_034 27 วันที่ผ่านมา +5

    A nice video. I´m a mechanical engineeing and i started learning to program as a hobby. Your videos have always helped me a lot to understand and learn.

    • @PatrickGod
      @PatrickGod  27 วันที่ผ่านมา +1

      Cool, thank you so much for your feedback!

  • @FredvonHayek
    @FredvonHayek 15 วันที่ผ่านมา +1

    Best video on this subject I have found anywhere. Well done, sir.

    • @PatrickGod
      @PatrickGod  14 วันที่ผ่านมา

      Thank you very much. Appreciate it. 😊

  • @hamadsherazi6896
    @hamadsherazi6896 18 วันที่ผ่านมา +1

    needed it immediately and exactly ran into the video at very appropriate time. thx patrick

    • @hamadsherazi6896
      @hamadsherazi6896 18 วันที่ผ่านมา

      One question, can we use this in production. The same strategy? Or is there something more to it?

  • @ionutvlad
    @ionutvlad 29 วันที่ผ่านมา +3

    Very nice video! I liked the step by step building, from simple to more complex.

  • @Chefrachida
    @Chefrachida หลายเดือนก่อน +15

    Great video. I hope you will consider making a video about Clean Architecture with Blazor in .NET 9 with us. Thank you for your work.

    • @PatrickGod
      @PatrickGod  หลายเดือนก่อน +2

      Noted😊

    • @amirameri1354
      @amirameri1354 หลายเดือนก่อน

      Yes . I needed to this tutorial so .Dear Patrick , We are waiting for it 🙏

    • @kevinespina3289
      @kevinespina3289 21 วันที่ผ่านมา

      @@PatrickGodyes please

  • @johnmaguire2185
    @johnmaguire2185 หลายเดือนก่อน +2

    Very impressive demonstration. Thanks Patrick.

  • @kriskata7653
    @kriskata7653 17 วันที่ผ่านมา +1

    Such a great video. It`s easy to follow and understand what is going on. Thanks Patrick.

  • @ashfaqmna6464
    @ashfaqmna6464 หลายเดือนก่อน +2

    It would be really great ,if u can make a video on Microsoft Identity with JWT in Web API.... this video is a good starting point to understand how JWT works ..and another great video!!!!

  • @innocentalfredo-youngboss
    @innocentalfredo-youngboss หลายเดือนก่อน +1

    Thank you for well organized and clear tutorial ,God bless u

  • @Steven-1183
    @Steven-1183 หลายเดือนก่อน +1

    I’m a recent subscriber, and I really appreciate your videos!

    • @PatrickGod
      @PatrickGod  หลายเดือนก่อน

      Awesome! Thank you! 🙏

  • @gustavougartetorres5714
    @gustavougartetorres5714 6 วันที่ผ่านมา +1

    I really like your videos, new sub from Perú

    • @PatrickGod
      @PatrickGod  5 วันที่ผ่านมา

      Thank you so much! And welcome! 😊

  • @tofu1687
    @tofu1687 3 วันที่ผ่านมา

    A very nice tuto to follow in order to understand the basics of authentication.
    A short-lived AccessToken allows you to disable the RefreshToken so that if the profile is compromised, the user won't be able to generate a new AccessToken. Also, if a user is completely removed from the DB (the employee has left the company), then the RefreshToken should not be usable to generate a new AccessToken.
    The RefreshToken endpoint should have an Authorize attribute and no parameters, the user's information is to be retrieved in the HttpContext, so RefreshToken should be added as a claim and not returned in the login response.

  • @dmsnm
    @dmsnm หลายเดือนก่อน

    Thank you for this very clear and concise video. Using Microsoft Identity for the user would be the only improvement I can point out.

  • @aabdoulraqeeb2468
    @aabdoulraqeeb2468 หลายเดือนก่อน +1

    Great Video man. I really like how you explain this stuffs man.

  • @blikardo
    @blikardo หลายเดือนก่อน

    Great video, really enjoyed the walk through. I'll try to implement this flow on my next project.

  • @Maikdorf
    @Maikdorf 5 วันที่ผ่านมา

    ❤❤❤❤❤❤
    How do you make the visual studio go so smoothly?
    What PC configuration do you have?

  • @cenkozturk5396
    @cenkozturk5396 18 วันที่ผ่านมา +1

    Thanks you my senior...

  • @emilie1977
    @emilie1977 หลายเดือนก่อน

    Thank you very much! Ciao from Italy

  • @omarabdelrahim8949
    @omarabdelrahim8949 18 วันที่ผ่านมา +1

    Thank you

  • @saeedkazeminia3637
    @saeedkazeminia3637 หลายเดือนก่อน +1

    Thanks a lot patrick

  • @TechhMann
    @TechhMann หลายเดือนก่อน

    Awesome video love this! Thank you

  • @LuisFernandoForeroGuzman
    @LuisFernandoForeroGuzman หลายเดือนก่อน +1

    Great video and explanation! I noticed you didn’t mention the Logout endpoint. Given that JWTs are stateless, what’s your opinion on implementing a logout endpoint using token blacklisting?

  • @ProtikPC_pro_indigo
    @ProtikPC_pro_indigo หลายเดือนก่อน +6

    Dear Patrick,
    As much as I like these bite-sized capsules where you emphasize and teach on a specific aspect/functionality or concept, I'd like you to start a series, where you build a real world COMPLETE application starting from scratch(preferably with Angular and .NetCore) bit by bit. For us, your valued subscribers.
    You probably have and sell course of platforms Udemy Coursera etc. but
    I request you, give us regular subscribers something to cherish.
    Hope you understand where I'm coming from.

    • @heathens2867
      @heathens2867 หลายเดือนก่อน

      Why don't you take advantage of LLM's? You're in 2025, it's hightime that you should take help of LLMs as they're highly capable and highly effective to teach u in very easy way.
      Get the jest of the project from these videos and apply it later with the help of LLMs

    • @ProtikPC_pro_indigo
      @ProtikPC_pro_indigo หลายเดือนก่อน

      @heathens2867 LLM ?

    • @rootbeer698
      @rootbeer698 หลายเดือนก่อน

      @@ProtikPC_pro_indigo Large Language Model like ChatGPT.

    • @SanityIT
      @SanityIT หลายเดือนก่อน

      @@ProtikPC_pro_indigo Fancy developer expression for AI.

    • @heathens2867
      @heathens2867 หลายเดือนก่อน +2

      @@SanityIT AI is an umbrella term and not specific to just LLMs. ANYWAY, I get the jest :p

  • @mlsandreas
    @mlsandreas หลายเดือนก่อน +1

    Thank you!

  • @ДмитрийКондратенко-б5ь
    @ДмитрийКондратенко-б5ь หลายเดือนก่อน +2

    Can you please make video about how to implement or adjust this authentication/authorisation in case if we have MVC application, not just Web API

  • @MJ-yx4ut
    @MJ-yx4ut 29 วันที่ผ่านมา

    Thank you for a great video. Would i be possible to create a video where you extend this with multitenancy?

  • @EvgeniyYatsenko
    @EvgeniyYatsenko หลายเดือนก่อน

    very helpful video!

  • @germanjesus214
    @germanjesus214 9 วันที่ผ่านมา

    como sugerencia, deberias agregar la opcion de traducir el video con voz en español, lo veo en muchos otros canales de idiomas diferente y es muy util, pero ahora tendre que usar una extension de doblaje, igual gracias por el contenido

  • @junyuzhu2459
    @junyuzhu2459 หลายเดือนก่อน +1

    amazing

  • @Leonidn1972
    @Leonidn1972 หลายเดือนก่อน

    Thanks a lot.The best chanel.
    Please,make real project with angular and .net core microservice.

  • @WingetOutdoors
    @WingetOutdoors 10 วันที่ผ่านมา

    Any plans on making a video on how to use this in a blazor page?

  • @tulnaf
    @tulnaf หลายเดือนก่อน

    Thank you again for the well explain tutorial.
    Can you make a video of how to use this Authentication with Blazor Server Web Application?

  • @imnash_on_E
    @imnash_on_E 13 วันที่ผ่านมา

    Very helpful, please apply this to Blazor WASM - Clean Architecture with an API/API controller.

  • @wrathrowe
    @wrathrowe 22 วันที่ผ่านมา +1

    Good morning, is there a compliment video to this one that shows how to use a Blazor WASM app to login?

    • @mtranchi
      @mtranchi 16 วันที่ผ่านมา +1

      I'd like to see this too, with roles being a separate class akin to how MS's Blazor WebApp implements authentication rather than just a string property on the User class

  • @sohailshamsramay
    @sohailshamsramay หลายเดือนก่อน +4

    I wonder, isn't it better to use Microsoft Identity as it does all heavy lifting for us and provide endpoints like /login, /register etc out of the box. Your thoughts @Patrick

    • @thiernodiallo575
      @thiernodiallo575 หลายเดือนก่อน +1

      I wanted to ask the same question.

    • @ProtikPC_pro_indigo
      @ProtikPC_pro_indigo หลายเดือนก่อน

      @@sohailshamsramay you mean like Azure AD B2C Auth Services ?

    • @sohailshamsramay
      @sohailshamsramay หลายเดือนก่อน

      @@ProtikPC_pro_indigoIts neither Azure AD nor B2C Auth Servies. I am talking about Microsoft.AspNetCore.Identity.EntityFrameworkCore package. If we use this package we only need to configure it in program.cs file as below;
      builder.Services.AddIdentityApiEndpoints()
      .AddEntityFrameworkStores();
      It does all the heavy lifting for us and provide endpoints linke login, register, forgotPassword, confirmEmail etc. I am new to AspNet world and really like it as I do not have to do more then just configuring it.

    • @sohailshamsramay
      @sohailshamsramay 26 วันที่ผ่านมา

      @@ProtikPC_pro_indigo No I mean installing following nuget package Microsoft.AspNetCore.Identity.EntityFrameworkCore and adding below configrations to program.cs file gives all the endpoints like login, register, forgotPassword etc out off the box.
      builder.Services.AddIdentityApiEndpoints()
      .AddEntityFrameworkStores();

  • @Sample-rn1pf
    @Sample-rn1pf 11 วันที่ผ่านมา

    Good

  • @whisperman4902
    @whisperman4902 หลายเดือนก่อน

    Hello, I am using Dotnet Identity but I think it does not have JWT feature, so I only add tables and managers. I continue with JWT myself. I started to question the benefits of this, would I be more comfortable with my own User like yours? What do you think?

  • @Nova5k
    @Nova5k 24 วันที่ผ่านมา

    I have a question about JWT. What happens if the refresh token and the access token are exposed to an attacker. In that case, does the hacker have the possibility to steal the user account unless the user login again right?

  • @pascalsi1
    @pascalsi1 หลายเดือนก่อน +2

    This is only the server part (WebApi) ?! How do I use that to login to my Blazor WASM standalone app for example, And once logged in make additional REST calls to some secured endpoints of the Web API by adding those token in the HTTP request header my Blazor WASM app will send to the Web API ? Some endpoints will be secured other not, so if no user is logged in, no token will be in the HTTP header.

    • @pascalsi1
      @pascalsi1 หลายเดือนก่อน

      Can i use those tokens in my Blazor WASM standalone app to allow the logged in user to access or not some pages based on its roles ?

  • @astheras
    @astheras หลายเดือนก่อน

    Do I understand correctly that you always connect to the database with only one user and do not use the auth creds to connect to the db?

  • @yashkushwaha7951
    @yashkushwaha7951 หลายเดือนก่อน +1

  • @Bakry5
    @Bakry5 หลายเดือนก่อน +1

    I click like button before I watch this course 🫶🩷🩷

  • @catalinmarianmursa7892
    @catalinmarianmursa7892 22 วันที่ผ่านมา +1

    Thank you !