92 points · by harporoeder · 4y ago · 38 comments
Going to be in a world of hurt once a slow-path DDoS packets come rolling in.
Is there a way to protect against that type of DDOS you raised?
This is behavior is manipulated by non-targeted congestion control schemes like Random Early Detect and targeted schemes like traffic policing and shaping.
Beyond consuming slow path resources, you might also be interested in SYN cookies to mitigate state-table exhaustion attacks.
Note that UDP, by itself, does not respond to loss in the same way. Any congestion control would have to be implemented at the application level, although policing / shaping are frequently applied to UDP traffic with good effect.
One minor nitpick, though: these tools are generally, but not always, effective at mitigating single-source DoS attacks. For volumetric DDoS, they don’t really work at all. For those, you need a provider, like Cloudflare or Akamai who can divert the malicious traffic away from your network. By the time the end network receives those packets, the damage is almost always done - it really doesn’t matter if you drop or forward at that point, if 100% of your Internet connection is filled with malicious traffic.
[0] - https://witestlab.poly.edu/blog/tcp-congestion-control-basic...
https://en.wikipedia.org/wiki/Multilayer_switch
See for an intro.
Think of it like this: sig: abc Traffic a[1] b[2] c[3]
where the packets are properly ordered in 1 2 3 order. Simple fragmentation could be sending them out of order - I believe this paper accounts for that. What if instead you send a[1] b[2] b[2] c[3]? Windows assembles this one way (depending on the version), linux another, bsd another. It's super fun. Then what if you send c[3] b[2] c[3] a[1] b[2]. One could argue, "hey d*ckhead we're going to normalize the traffic first" the problem is what is normal? Stevens had tons of good work on this. Some systems have a 'normalization' standard that's similar to how their network gear works. Also I find the fact that they say 'all the patterns' must be matched for the sig to fire. Does that include an or? Are they breaking the or down into sub detectors or something? The 10,000 signature thing is also kind of fake as the number of signatures constantly grows like the number of amazing taylor swift songs.
All in all these authors need to go read the old breakingpoint test standards, or ixia, or nss, or really anyone.
This all has very real world applications like with Corelight.
This is why this kind of IPS integrates with a firewall well. Two decades back, my team built very fast for its day firewall that would only let assembled-and-refragmented fragments through.
There was no confused ordering past the firewall, and no scenario of IDS/IPS and victim defragmenting differently.
* https://www.arista.com/en/solutions/tap-aggregation-with-dan...
The hosts would run software like Suricata, which is multi-threaded, and so can take advantage of many cores. (Until recently (3.0?) Snort was single-threaded.)
Achieving 100Gbps intrusion prevention on a single server - https://news.ycombinator.com/item?id=25108392 - Nov 2020 (35 comments)
That being said, I’m interested to see anomaly detection engines that learn data patterns and flag potentially malicious traffic.
[1] https://www.usenix.org/system/files/osdi20-zhao_zhipeng.pdf