News for hackers. Stuff that matters.
Re:Mitigating a DDoS on Mastodon by koroshitekure on Friday December 06, 2019 @07:03AM (#21721057)
hey, i'm the author of the article

really... surprised it got submitted here

incidentally i'm running pleroma, not mastodon. minor detail but you know

Re:Mitigating a DDoS on Mastodon by dredmorbius on Friday December 06, 2019 @09:14AM (#21721878)
I'm quite active on Mastodon and HN, thought this might be of interest.

Would you prefer the title were modified? The mods can do that. I thought that specifying what the DDoS mitigation was applied to would be helpful, though my presumption of Mastodon was in error, apologies.

Re:Mitigating a DDoS on Mastodon by koroshitekure on Friday December 06, 2019 @10:01AM (#21722313)
I'm not too bothered about correcting it, just thought it good to note
Re:Mitigating a DDoS on Mastodon by iampims on Friday December 06, 2019 @07:24AM (#21721162)
To avoid leaking IPs, you can use cloudflared tunnel. It might get pricy if you move a lot of bytes, but it’ll isolate you from IP leaking issues.
Re:Mitigating a DDoS on Mastodon by koroshitekure on Friday December 06, 2019 @07:27AM (#21721176)
oh, i found out where the leak was

it's right at the end of the article - the attacker was abusing the "create a preview card of any posted URL" feature - he'd post a link, wait for pleroma to go and grab the url to preview it, then narrow down which one was mine based on user agent

i added an upstream proxy and anonymised the user agent, so even if he were to do that, the most he'd find was my proxy box

Re:Mitigating a DDoS on Mastodon by chvanikoff on Friday December 06, 2019 @10:09AM (#21722396)
That might be what you are talking about, but just to confirm: Pleroma has an ability to proxy outbound requests via `pleroma.http` config out of the box
Re:Mitigating a DDoS on Mastodon by koroshitekure on Friday December 06, 2019 @10:15AM (#21722457)
yeah that's what I'm using

I also pull-requested a user agent anonymisation setting (pleroma.http.user_agent) to make this better

Re:Mitigating a DDoS on Mastodon by TrueDuality on Friday December 06, 2019 @12:10PM (#21723766)
Did you consider using Tor to make those kind of outbound requests? I've done that in that past for a similar situation to avoid leaking IPs, there is a latency overhead but it solved my issue pretty quickly. There were some sites that were blocking Tor exits but the vast majority were successful (enough that when the feature failed it didn't really matter).
Re:Mitigating a DDoS on Mastodon by netsectoday on Friday December 06, 2019 @02:14PM (#21725014)
I block all Tor traffic with iptables and ipset - which allows O(log n) lookup time for each request when checking it against the Tor list. I wonder if this would have been your end-all solution. http://ipset.netfilter.org/ipset.man.html