Joe Grandja 2 months ago
parent
commit
67c3ceb611
  1. 2
      web/src/main/java/org/springframework/security/web/FormPostRedirectStrategy.java
  2. 2
      web/src/main/java/org/springframework/security/web/server/FormPostServerRedirectStrategy.java

2
web/src/main/java/org/springframework/security/web/FormPostRedirectStrategy.java

@ -101,7 +101,7 @@ public final class FormPostRedirectStrategy implements RedirectStrategy { @@ -101,7 +101,7 @@ public final class FormPostRedirectStrategy implements RedirectStrategy {
// @formatter:off
final String html = REDIRECT_PAGE_TEMPLATE
// Clear the query string as we don't want that to be part of the form action URL
.replace("{{action}}", HtmlUtils.htmlEscape(uriComponentsBuilder.query(null).build().toUriString()))
.replace("{{action}}", HtmlUtils.htmlEscape(uriComponentsBuilder.replaceQuery(null).build().toUriString()))
.replace("{{params}}", hiddenInputsHtmlBuilder.toString())
.replace("{{nonce}}", HtmlUtils.htmlEscape(nonce));
// @formatter:on

2
web/src/main/java/org/springframework/security/web/server/FormPostServerRedirectStrategy.java

@ -105,7 +105,7 @@ public final class FormPostServerRedirectStrategy implements ServerRedirectStrat @@ -105,7 +105,7 @@ public final class FormPostServerRedirectStrategy implements ServerRedirectStrat
// @formatter:off
final String html = REDIRECT_PAGE_TEMPLATE
// Clear the query string as we don't want that to be part of the form action URL
.replace("{{action}}", HtmlUtils.htmlEscape(uriComponentsBuilder.query(null).build().toUriString()))
.replace("{{action}}", HtmlUtils.htmlEscape(uriComponentsBuilder.replaceQuery(null).build().toUriString()))
.replace("{{params}}", hiddenInputsHtmlBuilder.toString())
.replace("{{nonce}}", HtmlUtils.htmlEscape(nonce));
// @formatter:on

Loading…
Cancel
Save