Revoking issued tokens
This recipe helps you to revoke client access tokens, which is defined by the Token Revocation specification defined by RFC 7009 at https://tools.ietf.org/html/rfc7009. As per the specification, this OAuth 2.0 profile was created to allow clients to notify the Authorization Server that an access token or refresh token is no longer needed. This provides the Authorization Server with the ability to clear unused tokens in the database, thus avoiding useless data. Besides the revocation support, this recipe will help you to create an OAuth 2.0 Provider which also serves a user profile API, as we did for previous recipes in this book.
Getting ready
To run this recipe, you will need Java 8, Maven, MySQL, and your preferred IDE. As we will use Spring Boot, it's also recommended that you create an initial project using Spring Initializr.
How to do it...
The next steps will show how you can create an Authorization Server that implements a token revocation profile:
- Create the project...