Class InMemoryOAuth2AuthorizedClientRepository

  • All Implemented Interfaces:
    org.springframework.security.oauth2.client.web.OAuth2AuthorizedClientRepository

    @Deprecated
    public class InMemoryOAuth2AuthorizedClientRepository
    extends Object
    implements org.springframework.security.oauth2.client.web.OAuth2AuthorizedClientRepository
    Deprecated.
    Please use SynchronizedDelegatingOAuth2AuthorizedClientManager or InMemoryOAuth2AuthorizedClientService, which is used internally by SynchronizedDelegatingOAuth2AuthorizedClientManager.
    In-memory implementation of OAuth2AuthorizedClientRepository that provides support for storing OAuth2AuthorizedClient for service-to-service communications.

    This stores the OAuth2AuthorizedClient by the client registration ID irrespective of any Authentication or HttpServletRequest. This should not be used when it is essential to tie the stored OAuth2AuthorizedClient to the user or session.

    Author:
    Nick Crum (ncrum)
    • Constructor Detail

      • InMemoryOAuth2AuthorizedClientRepository

        public InMemoryOAuth2AuthorizedClientRepository()
        Deprecated.
    • Method Detail

      • loadAuthorizedClient

        public <T extends org.springframework.security.oauth2.client.OAuth2AuthorizedClient> T loadAuthorizedClient​(String clientRegistrationId,
                                                                                                                    org.springframework.security.core.Authentication authentication,
                                                                                                                    javax.servlet.http.HttpServletRequest request)
        Deprecated.
        Specified by:
        loadAuthorizedClient in interface org.springframework.security.oauth2.client.web.OAuth2AuthorizedClientRepository
      • saveAuthorizedClient

        public void saveAuthorizedClient​(org.springframework.security.oauth2.client.OAuth2AuthorizedClient authorizedClient,
                                         org.springframework.security.core.Authentication authentication,
                                         javax.servlet.http.HttpServletRequest request,
                                         javax.servlet.http.HttpServletResponse response)
        Deprecated.
        Specified by:
        saveAuthorizedClient in interface org.springframework.security.oauth2.client.web.OAuth2AuthorizedClientRepository
      • removeAuthorizedClient

        public void removeAuthorizedClient​(String clientRegistrationId,
                                           org.springframework.security.core.Authentication authentication,
                                           javax.servlet.http.HttpServletRequest request,
                                           javax.servlet.http.HttpServletResponse response)
        Deprecated.
        Specified by:
        removeAuthorizedClient in interface org.springframework.security.oauth2.client.web.OAuth2AuthorizedClientRepository