Interface TokenManagementService

All Known Implementing Classes:
TokenManagementServiceImpl

@Service public interface TokenManagementService
A service for managing token related operations like invalidating/blacklisting tokens- or verifying their availability.
  • Method Details

    • blacklistToken

      void blacklistToken(String token)
      Blacklist a token.
      Parameters:
      token - The token to blacklist.
    • isBlacklisted

      boolean isBlacklisted(String token)
      Checks if a token is blacklisted or not.
      Parameters:
      token - The token to check.
      Returns:
      true if the token is blacklisted, false otherwise.
    • addToken

      void addToken(String token)
      Adds a token to the database.
      Parameters:
      token - The token to be added.
    • deleteExpiredTokens

      void deleteExpiredTokens()
      Deletes expired tokens from the database.