Example to add a self-created JWT using Springframework 6/ Spring Boot 3 ending in simple method security for controller actions.
💼 You will need:
- Docker according to your OS.
- Go to project root
docker compose builddocker compose up
💼 You will need:
- Docker according to your OS
- Java 17 installed on your machine
- JAVA_HOME set in your OS.
mvn clean spring-boot:run -Dspring-boot.run.jvmArguments="-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005"
- In root folder you find User.http (Vscode). There you could test the API.
GET http://localhost:8080/api/auth/login HTTP/1.1
Authorization: Basic ADM1 password
- You could run the test
mvn test