Skip to content

RedirectView does not URL encode expanded path variable [SPR-8646] #13288

@spring-projects-issues

Description

@spring-projects-issues

!!Use pwebb rather than philw opened SPR-8646 and commented

When using RedirectView to redirect to a URL that includes a path variable the model value is not correctly URL encoded. This differs from the query parameter where URL encoding occurs.

Eg:

RedirectView view = new RedirectView("/ab/{cd}");
view.render(Collections.singletonMap("cd", "C D"), request, response);
// Currently throws URISyntaxException, Should redirect to /ab/C+D

Affects: 3.1 M2

Referenced from: commits 498d81f

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: bugA general bug

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions