Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bandwidth and CPU drain #48

Open
BradPerbs opened this issue Jun 9, 2020 · 7 comments
Open

Bandwidth and CPU drain #48

BradPerbs opened this issue Jun 9, 2020 · 7 comments

Comments

@BradPerbs
Copy link

Any tip to reduce the CPU and bandwidth usage?

I'm currently using 2x KVM VPS in round robin with 20 and 8 cores, but with a simple attack, I reach 700 Mbit on both and 100% CPU usage.

Maybe a mitigation system that ban the hosts in netflow could work?

If you have any suggestion please let me know

@BradPerbs
Copy link
Author

any ideas on how to filter that 80%?

@hroost
Copy link

hroost commented Jul 15, 2020

Use services that provide ddos mitigation

@BradPerbs
Copy link
Author

Use services that provide ddos mitigation

For "services" you mean providers? because in that case will not work, since that mitigate only Layer 3/4 traffic, not layer 7 HTTP legitimate traffic

@C0nw0nk
Copy link
Owner

C0nw0nk commented Jul 19, 2020

This is where things get complex and I could solve it by allowing the script to take control of the servers built in firewall. For windows server users this would be netsh advfirewall and Linux would be iptables -A INPUT -s 192.168.0.1 -j DROP

I have the ability with Nginx Lua to access os.execute in order to run such things through a command line or console but i am looking at io.popen a bit more since os.execute blocks threads and workers while they run and io.popen is non blocking so will allow others users requests to finish and connect still.

@ti-bone
Copy link

ti-bone commented Aug 7, 2022

This is where things get complex and I could solve it by allowing the script to take control of the servers built in firewall. For windows server users this would be netsh advfirewall and Linux would be iptables -A INPUT -s 192.168.0.1 -j DROP

I have the ability with Nginx Lua to access os.execute in order to run such things through a command line or console but i am looking at io.popen a bit more since os.execute blocks threads and workers while they run and io.popen is non blocking so will allow others users requests to finish and connect still.

Check this https://github.com/juce/lua-resty-shell

@AndreiG6
Copy link

AndreiG6 commented Oct 11, 2022 via email

@wumingpc
Copy link

wumingpc commented Aug 25, 2023

Hi, you can try third-party free DDOS/HTTP Flood defense with unlimited traffic Layer L3-4 defense www.freecdn.pw FreeCDN Accelerated Defense

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
7 participants
@hroost @C0nw0nk @AndreiG6 @BradPerbs @ti-bone @wumingpc and others