This is a Spring-boot authentication server application which authenticates a user and sends back a JSON Web Token. once authenticated these JSON Web tokens can be used by other applications to validate a user.
This application can be used as a template to create a standalone common authetication servers
features:
- This application utilizes Spring Security to block all incoming requests without proper authentication and authorization.
- It provides api to register a new user and save the user in the database. url '/register'
- It generates a new unique userId for every new user.
- It uses jdbc authentication to validate/autheticate users from MySQL database and JPA - Java Persistence API.
- It generates a new signed JWT for any request to authentication url '/authenticate'. (only if the user credentials are valid).
- Additionaly, this application also applie a filter before every subsequent requests to validate the token if any in the request body.