Interface AuthorizationRequestRepository<T extends org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>
-
- Type Parameters:
T- The type of OAuth 2.0 Authorization Request
- All Known Implementing Classes:
HttpSessionOAuth2AuthorizationRequestRepository
public interface AuthorizationRequestRepository<T extends org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>Implementations of this interface are responsible for the persistence ofOAuth2AuthorizationRequestbetween requests.Used by the
OAuth2AuthorizationRequestRedirectFilterfor persisting the Authorization Request before it initiates the authorization code grant flow. As well, used by theOAuth2LoginAuthenticationFilterfor resolving the associated Authorization Request when handling the callback of the Authorization Response.- Since:
- 5.0
- See Also:
OAuth2AuthorizationRequest,HttpSessionOAuth2AuthorizationRequestRepository
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description TloadAuthorizationRequest(javax.servlet.http.HttpServletRequest request)Returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestornullif not available.TremoveAuthorizationRequest(javax.servlet.http.HttpServletRequest request)Deprecated.default TremoveAuthorizationRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)Removes and returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestandHttpServletResponseor if not available returnsnull.voidsaveAuthorizationRequest(T authorizationRequest, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)Persists theOAuth2AuthorizationRequestassociating it to the providedHttpServletRequestand/orHttpServletResponse.
-
-
-
Method Detail
-
loadAuthorizationRequest
T loadAuthorizationRequest(javax.servlet.http.HttpServletRequest request)
Returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestornullif not available.- Parameters:
request- theHttpServletRequest- Returns:
- the
OAuth2AuthorizationRequestornullif not available
-
saveAuthorizationRequest
void saveAuthorizationRequest(T authorizationRequest, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
Persists theOAuth2AuthorizationRequestassociating it to the providedHttpServletRequestand/orHttpServletResponse.- Parameters:
authorizationRequest- theOAuth2AuthorizationRequestrequest- theHttpServletRequestresponse- theHttpServletResponse
-
removeAuthorizationRequest
@Deprecated T removeAuthorizationRequest(javax.servlet.http.HttpServletRequest request)
Deprecated.Removes and returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestor if not available returnsnull.- Parameters:
request- theHttpServletRequest- Returns:
- the removed
OAuth2AuthorizationRequestornullif not available
-
removeAuthorizationRequest
default T removeAuthorizationRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
Removes and returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestandHttpServletResponseor if not available returnsnull.- Parameters:
request- theHttpServletRequestresponse- theHttpServletResponse- Returns:
- the
OAuth2AuthorizationRequestornullif not available - Since:
- 5.1
-
-