Package org.springframework.security.web
Class FormPostRedirectStrategy
java.lang.Object
org.springframework.security.web.FormPostRedirectStrategy
- All Implemented Interfaces:
RedirectStrategy
Redirect using an auto-submitting HTML form using the POST method. All query params
provided in the URL are changed to inputs in the form so they are submitted as POST
data instead of query string data.
- Since:
- 6.5
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
sendRedirect
(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, String url) Performs a redirect to the supplied URL
-
Constructor Details
-
FormPostRedirectStrategy
public FormPostRedirectStrategy()
-
-
Method Details
-
sendRedirect
public void sendRedirect(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, String url) throws IOException Description copied from interface:RedirectStrategy
Performs a redirect to the supplied URL- Specified by:
sendRedirect
in interfaceRedirectStrategy
- Parameters:
request
- the current requestresponse
- the response to redirecturl
- the target URL to redirect to, for example "/login"- Throws:
IOException
-