How to do it...

The next steps will show you how to create the OAuth 2.0 Provider, which was named pop-server. This project is also available on GitHub in the Chapter05 folder:

  1. First of all, create the pop-server project as a Spring Boot application (I recommend the usage of Spring Initializr). At Spring Initializr add Web, Thymeleaf and Security as dependencies.
  2. Import the pop-server project to your IDE as a Maven project and add the following dependencies into the pom.xml file:
<dependency>  <groupId>org.springframework.security.oauth</groupId>  <artifactId>spring-security-oauth2</artifactId>  <version>2.2.0.RELEASE</version><!--$NO-MVN-MAN-VER$ --></dependency><dependency>  <groupId>org.springframework.security</groupId>  <artifactId>spring-security-jwt ...

Get OAuth 2.0 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.