ASP.NET Core 3 - Authentication - Ep.1 Basics (UPDATED: READ DESCRIPTION)

Raw Coding · 366K views · 2019 · 21:32

Open on YouTube

Web developmentSoftware practice, open source & careerstutorialdated

Why Stack Overflow recommends it

Stack Overflow users link it when answering ASP.NET Core authentication questions, especially for explaining claims, cookie auth and how [Authorize] roles map to identity claims.

Recommended by 4 people across 4 different months, 2020 to 2022.

What it is

A 21-minute tutorial from the Raw Coding channel (Anton Toshik) that introduces authentication and authorization basics in ASP.NET Core 3, including claims, ClaimsIdentity and ClaimsPrincipal with cookie-based login. It is the first episode of a series, and the description points to an updated playlist.

What people said

Recommends Kishan Vaishnav · 2020-06 · Stack Overflow · on “.NET Core Api authentication using Identity server 4”

The responsibility of creating and maintaining users is of the Authentication Server. Where I should put the Login and Register functionality So, the Identity Server project would contain endpoints like Register, Login, Forgot password, etc. How can I add the users to my database and authenticate the database user not the Test one. Microsoft Identity Core You can implement Microsoft Identity Core [LINK] which provides all the functionalities related to Account management. And there is built-in support for it in the IdentityServer4. This way you would not have to worry about code or the database. Note: The Microsoft Identity Core does a lot of things under the hood so you won't be able to und

Recommends Lukas · 2020-07 · Stack Overflow · on “What is the code that checks Roles with [Authorize] attribute using custom storage providers for Identity?”

I did more research and found a great series of tutorials: [this video] In the 4th video at 20:13 [LINK] , the Role in [Authorize] attribute is explained. The [Authorize] attribute uses the role value and simply compares it to the role claim of the identity. From what I understand, that's really it and implementation of custom storage providers isn't directly related to this.

Recommends Ashish Deora · 2021-05 · Stack Overflow · on “Who provides client id and client secret with Identity Server 4?”

The primary job of IdentityServer(IS4) is to manage the identity of the users. It is responsible for authentication and authorization (if claims are configured in it). The this thread [LINK] is a very detailed explanation of it. To be honest, I myself found IS4 very confusing when I came across it. I was new to C# and suddenly my employer asked me to deal with it. However over time, I realized its beauty and its universal flexibility. You should check out this series [this video] to know more about it (and identity management in C# in general). To answer your question, you will not only deploy IS4, you will also deploy your Client (API or MVC app). Your client will rely on idenityserver for authe

Recommends MaxK123 · 2021-06 · Stack Overflow · on “ASP.net Core MVC Login”

I got it working! I used this tutorial on [this video] ! It shows you have to use claims and use cookies, I made a special variant of it with sha256 + salt password encryption. Thanks everyone for your time and help!

Cites user7217806 · 2021-03 · Stack Overflow · on “Asp.Net Core Web Api and ReactJS: authentication with external login provider without identity”

In case you are referring to OpenID Connect [LINK] : React app The react app probably wants to initiate the authentication, get hold of the access token [LINK] which needs to be included in requests to the API, as well as refresh the access token once it is expired. You don't strictly need a library for that, but it makes your life easier, especially if you use one specific to react, like React OIDC [LINK] , which is a wrapper for the oidc-client. An example for including the token in API requests when using axios-hooks [LINK] can be found in the Authentication and token refresh [LINK] example. See bearer token [LINK] for further information. Web API To handle the access token provide by the

Cites mateuszwdowiak · 2021-05 · Stack Overflow · on “React SPA with .net core API, authentication”

I would like to write a SPA application in React that will communicate with the .net core API. I think it would be easier to have two separate projects (API + UI) on different domains. API should be protected, that only authenticated users could make requests. In react i'd like to have login and registration forms that will allow me to register and login users, and also I would like to have social providers. I would like to create whole UI for managing users in react SPA, and saving this data using API. I did a lot of research, and I'm a little confused. I would really like to use Core Identity because it simply looks like made for it [LINK] it has a ready to go model of Users, Claims, Roles

Cites Rouzbeh Zarandi · 2022-09 · Stack Overflow · on “Microservice architecture structure with docker-compose : .NET 6”

q1: ocelot is an API GATEWAY which is the entry point for your requests. so it should be the first layer/service meet by user request in front of your services and it forwards the request to the service according to its configuration. so it is lay in the front for all services you have. some arch provide another api gateway for different reasons like specific api gateway for mobiles request for example. q2: as looking separate services (i cant understand function api but i assume they are services also ) yes but the microservices development is not just about separating things, its about design and identifying the services from business context (Domain Driven Design).its very challenging to