Giter VIP home page Giter VIP logo

trusona-oidc-springboot-example's Introduction

Trusona OpenID Connect Example using Java and Spring Boot

This project demonstrates integrating Java and Trusona using Spring Boot.

Signup for a Trusona Developers account at https://developers.trusona.com/

Requirements

  • Trusona developer account
  • Familiarity with the Spring Boot framework

Project setup

  1. Checkout the project from GitHub
  2. 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.
  3. You'll receive an email back with your OIDC client ID
  4. Edit src/main/resources/application.properties enter your client ID for the key oidc.clientId
  5. Run ./gradlew bootrun

Using the example

  1. Open a browser and navigate to https://localhost:5001
  2. Click the "Login with Trusona button" that you see on the screen
  3. Open the Trusona App on your phone
  4. Now that you've been redirect to the Trusona Gateway, use the Trusona App to scan the QR code on your screen
  5. Tap "Accept" in the Trusona App
  6. Now you've been redirected back to the example application running on your machine
  7. See the user information displayed on the screen that indicates a successful login

What's going on?

  1. A request is prepared that will redirect the user to the Trusona Gateway and start the OIDC flow. See the OidcController.java
  2. The user clicks the login button which triggers the redirect to the Trusona Gateway. See the oidc.html template
  3. Now the user is on the Trusona Gateway and is ready to complete their authentication
  4. 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

trusona-oidc-springboot-example's People

Contributors

thitu avatar rtrusona avatar sealz avatar fosterhauz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.