Dateien

> > CS2D > Lua Scripts > Null-packet Protection
DateiübersichtCS2D-ÜbersichtLua Scripts-Übersicht

Englisch Null-packet Protection >

37 Kommentare6 kb, 531 Downloads

alt Null-packet Protection

Lee
Moderator Off Offline

If you're running a linux dedicated server and you don't have root access to set up iptable rules to mitigate these recent DoS attacks, you can now fix this from within Lua.

Just drop patch.so into sys/lua/patch.so and add
1
require 'sys.lua.patch'

into server.lua.

IMG:https://i.imgur.com/E37R9hE.png


Notice how the server is still processing new packets after null-packets are sent into it.
Zugelassen von Yates

Download Download

6 kb, 531 Downloads

Kommentare

37 Kommentare
Seite
Zum Anfang Vorherige 1 2 Nächste Zum Anfang

Logge dich ein!

Du musst dich einloggen, um selber Kommentare verfassen zu können!Einloggen

alt @lee

karthik
User Off Offline

For 1.0.0.7 available?

alt

kerker
User Off Offline

I like your program. Nice!
Ich mag es!

alt

floria
User Off Offline

@user GeoB99 oooh i understand.

Well, i will just get this if i do not have root/sudo privileges.
Ich mag es!

alt

GeoB99
Moderator Off Offline

@user floria: You completely misunderstood user Yates's comment. Not everybody is a Linux-geek especially when setting up iptable rules and exceptions within firewall configuration. Proper teaching and learning won't hurt but you can't apply to every single person as not everybody likes to read much.

Are you a Linux newbie? Get this tool! Can't set up iptable rules due to lack of administrative rights for some reason? Get this tool!
Ich mag es!

alt

floria
User Off Offline

user Yates hat geschrieben
Very useful for those who are not or cannot into Linux.

Dude Linux can be used in almost all pc's around the world. You can even use cs2d dedicated without graphical interface. You don't even need to install a linux distro in order to run it. And if you are not on Linux, download a freaking Ubuntu distro and run it into a VM. That's all: Linux > Windows.

user Lee: Nice work on this dude
Ich mag es!

alt

ead
User Off Offline

Our nice guy that will test soon, thank you.
Ich mag es!

alt

mrc
User Off Offline

Server still crash with attacks.

alt

Marco X
User Off Offline

It very nice
i think need add in debug like it "Caught a null packet from 127.0.0.1:2343".
Ich mag es!

alt

cartel
User Off Offline

Nice work !
Ich mag es!

alt

Lee
Moderator Off Offline

Yes, it's effectively the same thing. This script is targeted at people who don't have access to iptables for whatever reason, as long as they can upload scripts, they can still seek protection.

alt

mrc
User Off Offline

A friend of mine said this script is the same of: sudo iptables -A INPUT -p udp -m length --length 0:28 -j DROP

alt

Angel DEED
BANNED Off Offline

Thanks god
Ich mag es!

alt

Mami Tomoe
User Off Offline

The description tells me its compatible with Linux, it does not tell anything about windows and so I was asking to make sure.

alt

GeoB99
Moderator Off Offline

@user Mami Tomoe: If the description tells you that it's compatible with Linux dedicated servers, then what do you think?
Ich mag es!

alt

Mami Tomoe
User Off Offline

Is it Linux only?

alt

Gaios
Reviewer Off Offline

Yeah.. it's good √
Ich mag es!

alt

Marcell
Super User Off Offline

I love you Lee!
Ich mag es!

alt

Lee
Moderator Off Offline

@user mrc: is it still on-going? Furthermore, have you restarted your server since your original iptable rule? These rules are not persistent unless you are explicit about such things.

One of the things to note is that if ./cs2d_dedicated is inundated with random packets, it will take forever to process everything, but nevertheless, if you look at the log or the standard output of the process, it will still run smoothly. More importantly, it shouldn't crash. If your server is getting DDoSed and your process runs out of available space because of the incoming packets, then it means that the attacker is sending a sequence of well-formed packets that CS2D understands one after the other to trigger non-trivial workload. If I were you, I would set up a passive sniffer on 36963 and create a frequency table of the occurrence of each packet type broken down by each minute. Next time you get taken down, consult this histogram to see what's going on, and then create an iptable rule based on that.

alt

Nekomata
User Off Offline

Helpful and easy to implement. Thanks for sharing.
Ich mag es!

alt

mrc
User Off Offline

The attacks doesnt do a thing on vps, but the cs2d_dedicated stop responding. I already have an autorestart for cs2d_dedicated. Its annoying when people crash the serv when its full or while clanwars and mixes. Oh well.
Zum Anfang Vorherige 1 2 Nächste Zum Anfang