Comments (8)
https://en.wikipedia.org/wiki/Slowloris_(computer_security) coucou
from tiny_httpd.
I submitted a pull request #23 that probably address this
from tiny_httpd.
For slowloris we'd need to also realize that a given query has started more than n
seconds ago and isn't parsed yet, a mere timeout doesn't suffice (the client just adds a new fake header every 10 seconds or so).
from tiny_httpd.
I was trying to make my server usable by firefox which it was not with 20 simultaneous access or I would have needed much more max_connections.
Strangly, firefox is creating new connection except when connection is refused, then it tries to reuse old ones. But
when max_connections is reached problem starts ... I saw up to 10 connections for one client with firefox,
most of them unused.
For protection agains DDOS attack, I do not see how to recognize fake request, this is probably undecidable ;-).
A protection agains DDOS is probably to allow a maximum of request by second. But if the attacker has 1000 machines or more,
this seems very hard.
from tiny_httpd.
This is solved ?
from tiny_httpd.
If you think so, it can be closed :)
from tiny_httpd.
The socket timeout seems to work. I tested it with very short timeout and it was ok.
The only question is do we want a (long) timeout by default ? It the defaut usage of a server written with
Tiny_httpd is behind a proxy (apache or nginx) better have no timeout.
from tiny_httpd.
I think a default of no timeout is good.
from tiny_httpd.
Related Issues (20)
- allow user to setup info/debug/trace logs HOT 1
- basic "static file server" middleware HOT 1
- Problem with mime type of css and js files HOT 4
- Function `percent_decode` should not convert the `+` symbol HOT 2
- session and handling of body in post method HOT 7
- Unix.accept raising exception, not caught HOT 3
- Provide some level of statistics ? HOT 8
- test server sent events
- more serious testing HOT 4
- Better data structure for headers HOT 4
- Middleware and accept overlap a bit ? Need more freedom for composition ? HOT 2
- Stream do not close the file descriptor HOT 6
- Should use magic-mime (or mrmime) HOT 2
- Small file should not be chunked HOT 5
- missing code for trailer in chunked message HOT 3
- Accept-encoding and chunked response HOT 2
- handling of route HOT 11
- Firefox hang on 301 redirect with no body HOT 2
- examine problem with dune2
- allow path handlers to directly take a `byte_stream Request.t`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tiny_httpd.