Interface CorsProcessor
- All Known Implementing Classes:
DefaultCorsProcessor
public interface CorsProcessor
A strategy to apply CORS validation checks and updates to a
ServerWebExchange, either rejecting through the response or adding
CORS related headers, based on a pre-selected CorsConfiguration.- Since:
- 5.0
- Author:
- Sebastien Deleuze, Rossen Stoyanchev
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleanprocess(CorsConfiguration configuration, ServerWebExchange exchange) Process a request using the givenCorsConfiguration.
-
Method Details
-
process
Process a request using the givenCorsConfiguration.- Parameters:
configuration- the CORS configuration to use; possiblynullin which case pre-flight requests are rejected, but all others allowed.exchange- the current exchange- Returns:
falseif the request was rejected,trueotherwise
-