public class DefaultServlet
extends javax.servlet.http.HttpServlet
HttpHandler.handleRequest(io.undertow.server.HttpServerExchange)
method, otherwise the request is handled as a normal servlet request. By default we only allow a restricted set of extensions.
todo: this thing needs a lot more work. In particular: - caching for blocking requests - correct mime type - range/last-modified and other headers to be handled properly - head requests - and probably heaps of other thingsModifier and Type | Field and Description |
---|---|
static String | ALLOW_POST |
static String | ALLOWED_EXTENSIONS |
static String | DEFAULT_ALLOWED |
static String | DIRECTORY_LISTING |
static String | DISALLOWED_EXTENSIONS |
static String | RESOLVE_AGAINST_CONTEXT_ROOT |
Constructor and Description |
---|
DefaultServlet() |
Modifier and Type | Method and Description |
---|---|
protected void | doDelete(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
protected void | doGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
protected void | doOptions(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
protected void | doPost(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
protected void | doPut(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
protected void | doTrace(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) |
void | init(javax.servlet.ServletConfig config) |
doHead, getLastModified, service, service
public static final String DIRECTORY_LISTING
public static final String DEFAULT_ALLOWED
public static final String ALLOWED_EXTENSIONS
public static final String DISALLOWED_EXTENSIONS
public static final String RESOLVE_AGAINST_CONTEXT_ROOT
public static final String ALLOW_POST
public void init(javax.servlet.ServletConfig config) throws javax.servlet.ServletException
init
in interface javax.servlet.Servlet
init
in class javax.servlet.GenericServlet
javax.servlet.ServletException
protected void doGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doPost(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doPost
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doPut(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doPut
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doDelete(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doDelete
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doOptions(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doOptions
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doTrace(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doTrace
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
Copyright © 2020 JBoss by Red Hat. All rights reserved.