This repository demonstrates various authentication strategies implemented in a simple Weather API using simple Layered Architecture with ASP.NET Core. Each project is built independently to showcase a specific auth mechanism, making it easier for developers to learn and compare implementation patterns.
- Email: [email protected]
- GitHub: Vishwam
- LinkedIn: Vishwa Kumar
Vishwa is the primary developer and architect of this example app, responsible for the architecture and implementation of these features.
Project | Description |
---|---|
WeatherApp.RestApi.ApiKeyAuth |
Authenticates requests using custom API keys passed via headers. |
WeatherApp.RestApi.BasicAuth |
Implements HTTP Basic Authentication (username/password). |
WeatherApp.RestApi.JwtAuth |
Uses custom JWT token generation and validation logic. |
WeatherApp.RestApi.JwtAuthIdentity |
Leverages ASP.NET Core Identity for JWT authentication and user management. |
WeatherApp.RestApi.OAuth2Duende |
Demonstrates OAuth2/OpenID Connect using Duende IdentityServer. |
Each project contains its own solution and can be run/tested independently.
```bash
git clone https://github.com/vishwamkumar/weather-app.rest-apis.layered.git
cd weather-app.rest-apis.layered
```
```bash
cd WeatherApp.RestApi.JwtAuth
dotnet run
```
You can replace JwtAuth with any of the other auth project folders.
weather-app.rest-apis.layered/
├── WeatherApp.RestApi.ApiKeyAuth/
├── WeatherApp.RestApi.BasicAuth/
├── WeatherApp.RestApi.JwtAuth/
├── WeatherApp.RestApi.JwtAuthIdentity/
└── WeatherApp.RestApi.OAuth2Duende/
This project is licensed under the MIT License - see the LICENSE file for details.