This project implements JWT-based authentication and authorization using Spring Boot 3.4.3 and Spring Security. It provides user registration, login, and protected API endpoints that require authentication.
- User registration and login
- JWT-based authentication and authorization
- Role-based access control (RBAC)
- Secure API endpoints
- Spring Boot 3.4.3 & Spring Security
- Spring Boot 3.4.3
- Spring Security
- JSON Web Tokens (JWT)
- Java 21
- Maven
- MySQL (configurable)
Update application.properties (or application.yml) to configure database and JWT properties.
- POST /api/auth/register – Register a new user
- POST /api/auth/login – Authenticate and receive a JWT token
- GET /api/user/profile – Access a protected endpoint (requires authentication)
Chaima Jerbi