https://github.com/amirhnajafiz/checkpoint
Using JWT to authenticate the users of an web-application
https://github.com/amirhnajafiz/checkpoint
airbrake golang jwt jwt-authentication monitoring
Last synced: 3 months ago
JSON representation
Using JWT to authenticate the users of an web-application
- Host: GitHub
- URL: https://github.com/amirhnajafiz/checkpoint
- Owner: amirhnajafiz
- Created: 2021-12-20T08:35:11.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-08-27T06:25:58.000Z (about 3 years ago)
- Last Synced: 2024-06-21T08:29:12.220Z (over 1 year ago)
- Topics: airbrake, golang, jwt, jwt-authentication, monitoring
- Language: Go
- Homepage:
- Size: 589 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
![]()
CheckpointUsing JWT to authenticate the users of a web-application. The main idea
behind this project was to authorize our clients in a Golang service using JWT.## What do you learn from this project?
- Middlewares in Golang
- JWT
- Airbrake## What is JWT?
JSON Web Token (JWT) is an open standard
(RFC 7519) that defines a compact and self-contained
way for securely transmitting information
between parties as a JSON object.This information can be verified and
trusted because it is digitally signed.
JWTs can be signed using a secret
(with the HMAC algorithm) or a
public/private key pair using RSA or ECDSA.Read more about [JWT](https://jwt.io/introduction).
## What is Airbrake?
Airbrake is the world's leading error
tracking service. Thousands of engineering
teams all over the world use Airbrake to capture,
organize and alert their software exceptions,
allowing them to find and fix bugs more quickly.Read more about [Airbrake](https://www.airbrake.io/).
## How to use?
Clone the project and enter the following command:
```shell
go run main.go
```### Endpoints
- **/api/login**
- method = POST
- input: username, password
- **/api/register**
- method = POST
- input: username, password
- **/api/user**
- method = GET
- input: username, token [header]## Monitoring
Using airbrake dashboard to monitor our project:![]()