Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] DoS handling

Decided to give this a try. I basically just extended the Connector,
Connection and Endpoint classes and added an extra flag to the
connection object so that I can add the "Connection: close" header in
my handler implementation if this flag is present. i.e.,

      if (((ClampConnection) baseRequest.getConnection()).getClose()) {
        response.setHeader(HttpHeaders.CONNECTION, HttpHeaderValues.CLOSE);
      }

inside my handle() method.

https://github.com/chetan/sewer/tree/master/src/main/java/org/eclipse/jetty/io/nio

Feedback is welcome.


On Fri, Apr 13, 2012 at 3:36 PM, Chetan Sarva <csarva@xxxxxxxxx> wrote:
>
> AFAICT, I'll need to customize the SelectChannelConnector and/or the
> SelectorManager to make this happen. Are there any other options?


Back to the top