-
Notifications
You must be signed in to change notification settings - Fork 38.6k
Closed
Closed
Copy link
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)type: bugA general bugA general bug
Milestone
Description
Scott Andrews opened SPR-6296 and commented
The spring:url tag currently uses java.net.URLEncoder to URL encode template variables. URLEncoder does not follow raw URL encoding, but rather the application/x-www-form-urlencoded MIME format. This has the effect of encoding space charters as '+' instead of '%20'.
application/x-www-form-urlencoded is defined as part of the HTML spec (see http://www.w3.org/TR/html4/interact/forms.html#h-17.13.4.1) and not the URL spec. While the spring:url tag is often used for HTML, it should not be assumed that the URL will be used in HTML, or with an application/x-www-form-urlencoded content type.
Affects: 3.0 RC1
Issue Links:
- RestTemplate should encode the url variables [SPR-5516] #10187 RestTemplate should encode the url variables
Referenced from: commits 67b5781
Metadata
Metadata
Assignees
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)type: bugA general bugA general bug