T
T
TRUEC0DER2021-03-13 17:39:08
ubuntu
TRUEC0DER, 2021-03-13 17:39:08

How to set the maximum size of incoming traffic?

I monitor the traffic itself through jnettop, and I need to deny all traffic that exceeds a certain size, how can I do this?604cce5a7ca41942796866.jpeg

Answer the question

In order to leave comments, you need to log in

3 answer(s)
K
ky0, 2021-03-13
@ky0

What do you mean by "over a certain size"? Average speed from a specific IP address? Total downloaded/uploaded? And for what period? And if it is not within the same connection?
You can ask many more questions, but personally I'm too lazy - it's better to specify what you want and, most importantly, why.

A
Antonio Solo, 2021-03-14
@solotony

incoming - no way. traffic will still come, whether you like it or not.
but you can configure the rules for processing incoming traffic (both for the local machine and for the router)
traffic control (tc), iptables, firehol

A
AUser0, 2021-03-14
@AUser0

Incoming traffic (request to HTTP service) can be controlled in Apache/NGINX/other web server itself.
If the site is written in PHP, you can also control the size of the request there, but after the fact (an error will be thrown if the limit of XXX Mb is exceeded). The outgoing size can also be controlled, for example in PHP scripts - not to generate huge responses.
Just wondering, what the hell is this? Do you pay for traffic per megabyte? Or from the principle of "to spite my grandmother, we will freeze our ears"? You will lose users because of a buggy site ...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question