Interface RegisteredClientRepository

All Known Implementing Classes:
InMemoryRegisteredClientRepository, JdbcRegisteredClientRepository

public interface RegisteredClientRepository
A repository for OAuth 2.0 RegisteredClient(s).
Since:
0.0.1
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the registered client identified by the provided clientId, or null if not found.
    Returns the registered client identified by the provided id, or null if not found.
    void
    save(RegisteredClient registeredClient)
    Saves the registered client.
  • Method Details

    • save

      void save(RegisteredClient registeredClient)
      Saves the registered client.

      IMPORTANT: Sensitive information should be encoded externally from the implementation, e.g. RegisteredClient.getClientSecret()

      Parameters:
      registeredClient - the RegisteredClient
    • findById

      @Nullable RegisteredClient findById(String id)
      Returns the registered client identified by the provided id, or null if not found.
      Parameters:
      id - the registration identifier
      Returns:
      the RegisteredClient if found, otherwise null
    • findByClientId

      @Nullable RegisteredClient findByClientId(String clientId)
      Returns the registered client identified by the provided clientId, or null if not found.
      Parameters:
      clientId - the client identifier
      Returns:
      the RegisteredClient if found, otherwise null