mirror of
https://github.com/spring-projects/spring-boot.git
synced 2026-09-17 12:09:16 +00:00
Prior to this commit, Spring Boot would auto-configure the `ForwardedHeaderFilter`/`ForwardedHeaderTransformer` when the "NATIVE" strategy is chosen. Spring Framework now requires an explicit choice between the supported HTTP header variants as of spring-projects/spring-framework#37072. This commit adapts to this new behavior with the following: * the "FRAMEWORK" strategy now only applies to Spring MVC and Spring WebFlux applications, since "NATIVE" strategies are now a good choice for most deployments. * the format of HTTP headers is now configured with `spring.mvc.forwarded-headers.header-format` and `spring.webflux.forwarded-headers.header-format`, with additional options. The default header format is now "X-Forwarded-*" for both NATIVE and FRAMEWORK strategies. The reference documentation also reflects those changes. Closes gh-51030