Class WebSessionOAuth2ServerAuthorizationRequestRepository
java.lang.Object
org.springframework.security.oauth2.client.web.server.WebSessionOAuth2ServerAuthorizationRequestRepository
- All Implemented Interfaces:
ServerAuthorizationRequestRepository<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>
public final class WebSessionOAuth2ServerAuthorizationRequestRepository
extends Object
implements ServerAuthorizationRequestRepository<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>
An implementation of an
ServerAuthorizationRequestRepository that stores
OAuth2AuthorizationRequest in the WebSession.- Since:
- 5.1
- See Also:
-
AuthorizationRequestRepositoryOAuth2AuthorizationRequest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>loadAuthorizationRequest(org.springframework.web.server.ServerWebExchange exchange) Returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestornullif not available.reactor.core.publisher.Mono<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>removeAuthorizationRequest(org.springframework.web.server.ServerWebExchange exchange) Removes and returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestor if not available returnsnull.reactor.core.publisher.Mono<Void>saveAuthorizationRequest(org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest authorizationRequest, org.springframework.web.server.ServerWebExchange exchange) Persists theOAuth2AuthorizationRequestassociating it to the providedHttpServletRequestand/orHttpServletResponse.
-
Constructor Details
-
WebSessionOAuth2ServerAuthorizationRequestRepository
public WebSessionOAuth2ServerAuthorizationRequestRepository()
-
-
Method Details
-
loadAuthorizationRequest
public reactor.core.publisher.Mono<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest> loadAuthorizationRequest(org.springframework.web.server.ServerWebExchange exchange) Description copied from interface:ServerAuthorizationRequestRepositoryReturns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestornullif not available.- Specified by:
loadAuthorizationRequestin interfaceServerAuthorizationRequestRepository<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>- Parameters:
exchange- theServerWebExchange- Returns:
- the
OAuth2AuthorizationRequestornullif not available
-
saveAuthorizationRequest
public reactor.core.publisher.Mono<Void> saveAuthorizationRequest(org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest authorizationRequest, org.springframework.web.server.ServerWebExchange exchange) Description copied from interface:ServerAuthorizationRequestRepositoryPersists theOAuth2AuthorizationRequestassociating it to the providedHttpServletRequestand/orHttpServletResponse.- Specified by:
saveAuthorizationRequestin interfaceServerAuthorizationRequestRepository<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>- Parameters:
authorizationRequest- theOAuth2AuthorizationRequestexchange- theServerWebExchange
-
removeAuthorizationRequest
public reactor.core.publisher.Mono<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest> removeAuthorizationRequest(org.springframework.web.server.ServerWebExchange exchange) Description copied from interface:ServerAuthorizationRequestRepositoryRemoves and returns theOAuth2AuthorizationRequestassociated to the providedHttpServletRequestor if not available returnsnull.- Specified by:
removeAuthorizationRequestin interfaceServerAuthorizationRequestRepository<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest>- Parameters:
exchange- theServerWebExchange- Returns:
- the removed
OAuth2AuthorizationRequestornullif not available
-