public class SPFormAuthenticationRequestWrapper extends HttpServletRequestWrapper
ServletRequest.getParameter
.
In case origin getParameter() method returns null and there is a not null instance of {@see FormData), wrapper returns data from FormData instead.
Wrapper is a part of the fix of JBEAP-10449.BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH
Constructor and Description |
---|
SPFormAuthenticationRequestWrapper(HttpServletRequest request,
FormData formData,
byte[] bytes) |
Modifier and Type | Method and Description |
---|---|
ServletInputStream |
getInputStream()
The default behavior of this method is to return getInputStream() on the wrapped request object.
|
String |
getParameter(String name)
The default behavior of this method is to return getParameter(String name) on the wrapped request object.
|
Map<String,String[]> |
getParameterMap()
The default behavior of this method is to return getParameterMap() on the wrapped request object.
|
Enumeration<String> |
getParameterNames()
The default behavior of this method is to return getParameterNames() on the wrapped request object.
|
String[] |
getParameterValues(String name)
The default behavior of this method is to return getParameterValues(String name) on the wrapped request object.
|
Part |
getPart(String name)
The default behavior of this method is to call getPart on the wrapped request object.
|
Collection<Part> |
getParts()
The default behavior of this method is to call getParts on the wrapped request object.
|
authenticate, changeSessionId, getAuthType, getContextPath, getCookies, getDateHeader, getHeader, getHeaderNames, getHeaders, getHttpServletMapping, getIntHeader, getMethod, getPathInfo, getPathTranslated, getQueryString, getRemoteUser, getRequestedSessionId, getRequestURI, getRequestURL, getServletPath, getSession, getSession, getTrailerFields, getUserPrincipal, isRequestedSessionIdFromCookie, isRequestedSessionIdFromUrl, isRequestedSessionIdFromURL, isRequestedSessionIdValid, isTrailerFieldsReady, isUserInRole, login, logout, newPushBuilder, upgrade
getAsyncContext, getAttribute, getAttributeNames, getCharacterEncoding, getContentLength, getContentLengthLong, getContentType, getDispatcherType, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getProtocol, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRequest, getRequestDispatcher, getScheme, getServerName, getServerPort, getServletContext, isAsyncStarted, isAsyncSupported, isSecure, isWrapperFor, isWrapperFor, removeAttribute, setAttribute, setCharacterEncoding, setRequest, startAsync, startAsync
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAsyncContext, getAttribute, getAttributeNames, getCharacterEncoding, getContentLength, getContentLengthLong, getContentType, getDispatcherType, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getProtocol, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRequestDispatcher, getScheme, getServerName, getServerPort, getServletContext, isAsyncStarted, isAsyncSupported, isSecure, removeAttribute, setAttribute, setCharacterEncoding, startAsync, startAsync
public SPFormAuthenticationRequestWrapper(HttpServletRequest request, FormData formData, byte[] bytes)
public String getParameter(String name)
ServletRequestWrapper
getParameter
in interface ServletRequest
getParameter
in class ServletRequestWrapper
name
- a String
specifying the name of the parameterString
representing the single value of the parameterServletRequest.getParameterValues(java.lang.String)
public String[] getParameterValues(String name)
ServletRequestWrapper
getParameterValues
in interface ServletRequest
getParameterValues
in class ServletRequestWrapper
name
- a String
containing the name of the parameter whose value is requestedString
objects containing the parameter's valuesServletRequest.getParameter(java.lang.String)
public Map<String,String[]> getParameterMap()
ServletRequestWrapper
getParameterMap
in interface ServletRequest
getParameterMap
in class ServletRequestWrapper
public Enumeration<String> getParameterNames()
ServletRequestWrapper
getParameterNames
in interface ServletRequest
getParameterNames
in class ServletRequestWrapper
Enumeration
of String
objects, each String
containing the name
of a request parameter; or an empty Enumeration
if the request has no parameterspublic Part getPart(String name) throws IOException, ServletException
HttpServletRequestWrapper
getPart
in interface HttpServletRequest
getPart
in class HttpServletRequestWrapper
name
- the name of the requested Part
Part
with the given name, or null
if this request is of type
multipart/form-data
, but does not contain the requested Part
IOException
- if an I/O error occurred during the retrieval of the requested Part
ServletException
- if this request is not of type multipart/form-data
MultipartConfig.maxFileSize()
,
MultipartConfig.maxRequestSize()
public Collection<Part> getParts() throws IOException, ServletException
HttpServletRequestWrapper
Any changes to the returned Collection
must not affect this HttpServletRequestWrapper
.
getParts
in interface HttpServletRequest
getParts
in class HttpServletRequestWrapper
Collection
of the Part
components of this requestIOException
- if an I/O error occurred during the retrieval of the Part
components of
this requestServletException
- if this request is not of type multipart/form-data
MultipartConfig.maxFileSize()
,
MultipartConfig.maxRequestSize()
public ServletInputStream getInputStream() throws IOException
ServletRequestWrapper
getInputStream
in interface ServletRequest
getInputStream
in class ServletRequestWrapper
ServletInputStream
object containing the body of the requestIOException
- if an input or output exception occurredCopyright © 2021 JBoss by Red Hat. All rights reserved.