Тёмный

.NET 7 Web API 🔒 Create JSON Web Tokens (JWT) - User Registration / Login / Authentication 

Patrick God
Подписаться 66 тыс.
Просмотров 81 тыс.
50% 1

Опубликовано:

 

11 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 59   
@saitoinosaka6445
@saitoinosaka6445 11 месяцев назад
if you are facing an error like Unable to create KeyedHashAlgorithm for algorithm 'HS512', the key size must be greater than: '512' bits, key has '256' bits. Arg_ParamName_Name. Just increase the token size in your settings.json
@kenneth6965
@kenneth6965 Год назад
This is personally my favorite part of your tutorials. All the way to refresh tokens. Thanks for this.
@PatrickGod
@PatrickGod Год назад
Happy to hear that! Thank you!
@AdeyinkaAdegbenro
@AdeyinkaAdegbenro Год назад
This is my most simpliest favorite authentication tutorial especially using hashPassword. Awesome Job Patrick!
@PatrickGod
@PatrickGod Год назад
Thank you so much for your feedback! Glad you like it! 😊
@alataherzadeh5761
@alataherzadeh5761 6 месяцев назад
nice. من ایرانی هستم. ممنون بابت اموزش عالی.💕💕💕💕💕💕💕💕💕💕
@okok-j4c8h
@okok-j4c8h 8 месяцев назад
I just Love the way you explain bro , thank you so much and carry on please 🙏🙏🙏
@RoyZASTEROiD
@RoyZASTEROiD Год назад
good reference in last test part
@PatrickGod
@PatrickGod Год назад
Glad it was helpful!
@colllm
@colllm Год назад
Superb explanation as usual Patrick. Thank you.
@PatrickGod
@PatrickGod Год назад
Many thanks!
@abdulmussavir4627
@abdulmussavir4627 Год назад
Hello Patric I like your teaching style and also love your codding style 🥰
@PatrickGod
@PatrickGod Год назад
Thank you very much, Abdul. I appreciate that. 😊
@MatthewCuda
@MatthewCuda Год назад
I love your style, very much the way I like to code.
@d-landjs
@d-landjs Год назад
Excellent bro, it was interesting!
@PatrickGod
@PatrickGod Год назад
Glad you enjoyed it!
@josephl
@josephl Год назад
Hi Patrick. I'm following your videos since the .NET 6 version of this topic. I remember back then you used HMACSHA512 to generate the password Salt. Does this mean HMACSHA512 will always generate the same Salt for the same input even though is in byte[] format?
@learn.net2202
@learn.net2202 Год назад
Please make video for logout in JWT token by invalidating token without storing token in database
@iEricoHD
@iEricoHD Год назад
This. I hope he makes a video on it. Best tutorials on Entity Framework by far.
@10Totti
@10Totti Год назад
Good tutorial!
@PatrickGod
@PatrickGod Год назад
Thank you so much!
@elishamisoi
@elishamisoi 7 месяцев назад
Thank you so much Patrick.
@jayantverma4639
@jayantverma4639 Год назад
Hello patrick How to store the Data in the sql database user login and regsitration ?
@pedrampourhakim3035
@pedrampourhakim3035 Год назад
Could you please tell us how we can logout the user? thanks
@PatrickGod
@PatrickGod Год назад
🚀 Get 20% off the .NET Web Academy: www.dotnetwebacademy.com/bundles/net-web-academy?coupon=dnwa2024yt
@orlandoubilla7055
@orlandoubilla7055 Год назад
Great video and explanation, thank you very! 😎✌
@slowmowfit
@slowmowfit Год назад
@PatrickGod There's no explanation as to how inputing Bear Token in the Swagger, unless I missed it?
@rezarst5734
@rezarst5734 7 месяцев назад
so useful, thank you
@phoolherreracondezo2841
@phoolherreracondezo2841 9 месяцев назад
i sheesh with that code very simple, thanks bro
@kwstaslalaounis3212
@kwstaslalaounis3212 Год назад
You are Perfect thank you.
@PatrickGod
@PatrickGod Год назад
Happy to help! Thank you very much!
@waqasawan4999
@waqasawan4999 11 месяцев назад
Nice video
@PatrickGod
@PatrickGod 11 месяцев назад
Thanks!
@KSUBlueDragon
@KSUBlueDragon Год назад
Why in the world would an api need to know more than just the fact it’s an authenticated user and has access? The UI should do the login and then pass the token generated then with a call that passes they are authenticated and maybe a app id to validate that said app has access to it.
@Sizdah_13
@Sizdah_13 7 месяцев назад
thank you , 💖💖
@onedev7316
@onedev7316 Год назад
Nice one, can you do a video on User impersonation using JWT ? Thanks
@daniel_klement_photography
@daniel_klement_photography Год назад
May I have a question about security? JWT is nice but is it a good idea to store there email or some user's data? Is'nt it better to control and check the JWT in the database if the user is logged in or not? Or what's the bet idea in this way how to secure the API?
@md.redwanhossain6288
@md.redwanhossain6288 11 месяцев назад
JWT is used for stateless authentication. If you hit the Database per request, there is no point for using JWT.
@samiullah0011
@samiullah0011 Год назад
my jwt is not validating after i create it can you help me?
@samsonmayeem5548
@samsonmayeem5548 Год назад
Bro, _configuration gives red flag, what's possibly the cause?
@chezchezchezchez
@chezchezchezchez Год назад
Please help. How do I make a API that returns a list of records filtered by the personId? I used the scaffolding API wizard. This is killing me. I have it working for getting all the records, but I can’t seem to add a Where clause. Thanks!!
@ydock
@ydock Год назад
without your code he cant help you but you can do something like this on your service _dataContext.YOUDBCONTEXTTABLE.Where(t => t.Enabled) .AsQueryable(); later you can call the service in your controller.
@chezchezchezchez
@chezchezchezchez Год назад
@@ydock I would be happy to show you my code, would you take a look?
@ritickkushwaha2835
@ritickkushwaha2835 7 месяцев назад
Is anyone know how to run this in postman..?
@user-dw9zz1zr9v
@user-dw9zz1zr9v Год назад
Hey can you make it with sql connection and some other features like pagination
@hungle-bp5qt
@hungle-bp5qt Год назад
why he dont use sql connention ha
@choudharyd4927
@choudharyd4927 Год назад
Token generated on stagging environment works in production and development too, can someone help how can separate token based on environment
@PatrickGod
@PatrickGod Год назад
You could use different signing keys for the different environments
@choudharyd4927
@choudharyd4927 Год назад
@@PatrickGod thankyou Patrick. Regards.
@unskeptable
@unskeptable 10 месяцев назад
When you call weather api how does it know to automatically call the auth/login controller to generate the token ? Where is this connection defined exactly ?I don't get it
@unskeptable
@unskeptable 10 месяцев назад
Ah ok I found out its defined in the loginPath variable of Identity options
@user-nm2el1xl5o
@user-nm2el1xl5o Год назад
I'd like to ask this. What is the advantage of using a custom authentication system rathen than using AD for instance? I know when one creates a project in VS, we have the option to select a auth system and it will be implemented and we can twist it.
@AdeyinkaAdegbenro
@AdeyinkaAdegbenro Год назад
Hi E243, from experience, especially if you are delivery SaaS, not all client may have AD that you can plug in to, you may want to have a fallback custom authentication system. I hope this helps. Cheers.
@user-nm2el1xl5o
@user-nm2el1xl5o Год назад
@adeyinkaroyal Make sense, but when a customer sign up, those information aren't going to be saved in Azure? I don't think one has to have credentials in AD. If I am wrong then it does make sense.
@AdeyinkaAdegbenro
@AdeyinkaAdegbenro Год назад
@@user-nm2el1xl5o Hi, was offline for a while. That's correct, it means on sign up, you manage the customer's data in your repository of choice, hence you can build your own custom authentication on it.
@ngocanh9250
@ngocanh9250 Год назад
Not useful
@ClickOkYT
@ClickOkYT Год назад
Why "SecurityAlgorithms.HmacSha512Signature" but not "SecurityAlgorithms.HmacSha512"?
Далее
ФОКУС -СВЕТОФОР
00:32
Просмотров 211 тыс.
Cute
00:16
Просмотров 6 млн
What Is JWT and Why Should You Use JWT
14:53
Просмотров 1,2 млн
Refresh Tokens with a .NET 6 Web API 🚀
25:41
Просмотров 47 тыс.
CQRS & MediatR in a .NET 8 Web API 🚀
22:00
Просмотров 9 тыс.
Should I Create A Minimal API Or Full API?
7:40
Просмотров 36 тыс.
Cursor Is Beating VS Code (...by forking it)
18:00
Просмотров 64 тыс.
ФОКУС -СВЕТОФОР
00:32
Просмотров 211 тыс.