-
Notifications
You must be signed in to change notification settings - Fork 40.9k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Encoded slash in path variable causes error 400 in WebFlux - regression in Spring Boot 3.3.5 #42907
Comments
I assume there is something else going on. import reactor.core.publisher.Mono;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
@RestController
public class TestController {
@GetMapping(path = "/api/{param}/foo", produces = MediaType.TEXT_PLAIN_VALUE)
public Mono<String> foo(@PathVariable String param) {
return Mono.just(param);
}
}
Maybe your application has Spring Security configured? |
I debugged that the issue is caused by I found that there is a method Why such breaking change was introduced in a hotfix version? |
I guess those are questions for the Spring Security team. Maybe ask this question on StackOverflow? |
I tried my custom The issue was that setting the firewall was added after the release: For a time being, I will use |
I develop a Spring WebFlux application with Netty.
After upgrade of Spring Boot from 3.3.4 to 3.3.5, http status 400 is returned when a path contains encoded slash.
The encoded slash is a part of path variable.
For example, the following endpoint returns status 400 for
GET /api/a%2Fb/foo
in 3.3.5.In 3.3.4, exactly same request returned 200 with
a/b
in the response.The text was updated successfully, but these errors were encountered: