Creating an Authentication System for Microservices with Identity Server 4
summary
Shows how to build an authentication system for microservices using IdentityServer4 and Azure API Management, providing runnable templates (empty project, UI, user admin) and sample clients that obtain tokens from the discovery endpoint. Implements OAuth2 flows (authorization code, client_credentials, resource owner password), issues tokens for test users (Alice/Bob), calls protected bookstore endpoints, and demonstrates API Management policies that enforce scopes/audience (returning 401 on mismatch); also notes HTTPS requirement and estimated API Management cost (~€400/month), with code and slides available for download.
AI-written summary · about
chapters (21)
- 0:00Introduction and speaker intro
- 1:22What we will cover today
- 3:09Microservices evolution and advantages
- 7:08Why authentication is needed
- 8:12IdentityServer4 roles explained
- 10:24Login flows and grant types
- 15:01Implementing IdentityServer4
- 20:44Creating the project with templates
- 23:21Configuring the IdentityServer4 project
- 26:26Adding users and clients
- 28:21Securing API endpoints
- 30:30Testing authentication with a client
- 33:16Adding test users
- 36:09CORS and domain restrictions
- 38:19Live demo login flow
- 40:19Microservices architecture overview
- 41:44API Gateway and management
- 43:06API management policies
- 44:33Testing API management
- 46:28Client credentials flow
- 49:23Q&A and closing remarks
related talks
59mBuilding APIs for developers with Identity Server 4
01h 03mBuilding Secure Microservices in Azure
01h 05mBuilding Secure Microservices in Azure
50mSecuring .NET Apps and Microservices in Azure
51mAuthentication and Authorization in ASP.NET Core 2
01h 03mIdentity Server 4 with Angular and ASP.NET Core
01h 02mDemystifying Web API Security in Azure
58mLet's talk Auth
