This project demonstrates integrating Java and Trusona using Spring Boot.
Signup for a Trusona Developers account at https://developers.trusona.com/
- Trusona developer account
- Familiarity with the Spring Boot framework
- Checkout the project from GitHub
- Email
[email protected]
and let them know that you want to run this example. Include the email that is displayed when you log in to your Trusona Developers account. - You'll receive an email back with your OIDC client ID
- Edit
src/main/resources/application.properties
enter your client ID for the keyoidc.clientId
- Run
./gradlew bootrun
- Open a browser and navigate to https://localhost:5001
- Click the "Login with Trusona button" that you see on the screen
- Open the Trusona App on your phone
- Now that you've been redirect to the Trusona Gateway, use the Trusona App to scan the QR code on your screen
- Tap "Accept" in the Trusona App
- Now you've been redirected back to the example application running on your machine
- See the user information displayed on the screen that indicates a successful login
- A request is prepared that will redirect the user to the Trusona Gateway and start the OIDC flow. See the OidcController.java
- The user clicks the login button which triggers the redirect to the Trusona Gateway. See the oidc.html template
- Now the user is on the Trusona Gateway and is ready to complete their authentication
- When the user returns to our example application with an ID token it is parsed and the claims information is displayed for your reference. See the OidcController.java and the success.html template