Merge branch 'master' into release-9

This commit is contained in:
Jesse McConnell 2014-04-01 09:00:23 -05:00
commit f842fe6c7c
1 changed files with 6 additions and 1 deletions

View File

@ -385,7 +385,7 @@ public class ProxyServlet extends HttpServlet
if (rewrittenURI == null)
{
response.sendError(HttpServletResponse.SC_FORBIDDEN);
onRewriteFailed(request, response);
return;
}
@ -490,6 +490,11 @@ public class ProxyServlet extends HttpServlet
proxyRequest.send(new ProxyResponseListener(request, response));
}
protected void onRewriteFailed(HttpServletRequest request, HttpServletResponse response) throws IOException
{
response.sendError(HttpServletResponse.SC_FORBIDDEN);
}
protected Request addViaHeader(Request proxyRequest)
{
return proxyRequest.header(HttpHeader.VIA, "http/1.1 " + getViaHost());