366774 removed XSS vulnerbility

This commit is contained in:
Greg Wilkins 2012-01-09 11:38:07 +11:00
parent c88a4551ae
commit 2451614381
1 changed files with 2 additions and 3 deletions

View File

@ -1027,12 +1027,11 @@ public class Request implements HttpServletRequest
try
{
if (_connection != null)
_connection._generator.sendError(HttpStatus.BAD_REQUEST_400,"Port couldn't be parsed from Host header: " + hostPort,null,
true);
_connection._generator.sendError(HttpStatus.BAD_REQUEST_400,"Bad Host header",null,true);
}
catch (IOException e1)
{
throw new IllegalArgumentException("IOException caught while trying to send error due to invalid host header: " + hostPort,e1);
throw new RuntimeException(e1);
}
}
return _serverName;