This is a webapi project written in visual studio and we will secure endpoint using JWT.
Basically, a JWT token look like:
<base64-encoded header>.<base64-encoded claims>.<base64-encoded signature>
JWT token has three sections:
- Header: JSON format which is encoded as a base64
- Claims: JSON format which is encoded as a base64.
- Signature: Created and signed based on Header and Claims which is encoded as a base64.
- I have used Restlet Client
- Updated to use Latest version of System.IdentityModel.Tokens.Jwt version=5.1.4
- Clone or download the repository
- You can find more details at my blog SECURING WEBAPI USING JSON WEB TOKEN(JWT) IN C#