public interface CorsProcessor
CorsConfiguration
and updates
the response.
This component is not concerned with how a CorsConfiguration
is
selected but rather takes follow-up actions such as applying CORS validation
checks and either rejecting the response or adding CORS headers to the
response.
AbstractHandlerMapping.setCorsProcessor(org.springframework.web.cors.CorsProcessor)
Modifier and Type | Method and Description |
---|---|
boolean |
processRequest(CorsConfiguration configuration,
HttpServletRequest request,
HttpServletResponse response)
Process a request given a
CorsConfiguration . |
boolean processRequest(CorsConfiguration configuration, HttpServletRequest request, HttpServletResponse response) throws IOException
CorsConfiguration
.configuration
- the applicable CORS configuration (possibly null
)request
- the current requestresponse
- the current responsefalse
if the request is rejected, true
otherwiseIOException