https://github.com/sandrinodimattia/aspnet-core-5-jwt-bearer-demo
JWT Bearer Authentication and Authorization for ASP.NET Core 5
https://github.com/sandrinodimattia/aspnet-core-5-jwt-bearer-demo
asp-net-core auth0 dotnetcore jwt
Last synced: 10 days ago
JSON representation
JWT Bearer Authentication and Authorization for ASP.NET Core 5
- Host: GitHub
- URL: https://github.com/sandrinodimattia/aspnet-core-5-jwt-bearer-demo
- Owner: sandrinodimattia
- License: mit
- Created: 2020-12-18T10:55:44.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-12-18T11:05:07.000Z (over 4 years ago)
- Last Synced: 2025-03-28T21:12:22.892Z (27 days ago)
- Topics: asp-net-core, auth0, dotnetcore, jwt
- Language: C#
- Homepage:
- Size: 8.79 KB
- Stars: 19
- Watchers: 3
- Forks: 6
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# JWT Bearer Authentication and Authorization for ASP.NET Core 5
Sample API which shows how to configure JWT Bearer Authentication and Authorization using an Open ID Connect / OAuth 2 Authorization Server (like Auth0, Okta, Identity Server, ...).
This sample API comes with 2 endpoints:
- `http://localhost:5001/api/claims` which requires the call to be authenticated
- `http://localhost:5001/api/billing/settings` which requires the call to be authenticated and the presence of a `read:billing_settings` scopeMore info is available in this blog post: https://sandrino.dev/blog/aspnet-core-5-jwt-authorization
## Running on MacOSX
You'll need to install the SDK for VS Code first:
https://dotnet.microsoft.com/download/dotnet-core/sdk-for-vs-code
The following command will help you solve any issues related to VS Code not being able to find the .NET SDK:
```bash
sudo ln -s /usr/local/share/dotnet/dotnet /usr/local/bin/dotnet
```### VS Code Extensions
Consider installing the following extensions for VS Code for a better editing experience:
- C#
- NuGet Gallery
- NuGet Package Manager