News for hackers. Stuff that matters.
Re:Self-hosted email is the hardest it's ever been, but also... by hardwaresofton on Monday September 05, 2022 @12:30AM (#32720529)
> But how much time do you spend dealing with that? Is it worth it?

Oh not much now -- to be honest with you 99% of the time when it's an issue it's because I changed something on my side.

Maybe I got lucky with the IPs I have (I use dedicated servers), and I've held them a while. What was jarring about the original post by Carlos is that he did all that AND he's been doing it 23 years and it was still a problem.

It made me recall that one of the things I struggled with a long time ago was just setting up Postfix/Dovecot correctly. These days no one should be running into that.

> I self hosted my email for more than a decade but I gave up when the time spent was just too much.

Unfortunately I don't doubt this assessment. I just want people to know that if difficulty/technical work was a blocker, it is now mostly not (with the news software out there).

As other people pointed out, there are services for improving deliverability that could fix the other (bigger) issue, and hopefully people could consider doing that going forward.

At the end of the day people have to do what's right for them of course but I just want people to know that things HAVE gotten easier. It's the big companies that are making it hard now.

Re:Self-hosted email is the hardest it's ever been, but also... by mrb on Monday September 05, 2022 @03:28AM (#32721507)
But Carlos did not do "all that". He said he tried VPS servers, not dedicated servers. Maybe that's his problem. VPS servers tend to have IP addresses with low reputation, whereas dedicated servers tend to have higher reputation IPs.

Deliverability really depend on solid reputation of IP address blocks, including reputation of your neighbors. Ideally you want an IP near other IPs who also send high volume of non-spam.

Re:Self-hosted email is the hardest it's ever been, but also... by denton-scratch on Monday September 05, 2022 @04:58AM (#32722015)
I used to self-host, on my home internet connection, for 20 years. I used ISPs that were email-friendly, and gave me clean IPs. I started out with Sendmail, but switched to Postfic/Dovecot after a few years.

I stopped a couple of years ago, and moved my mail to my ISPs servers (they let me use my own domain). I switched because of the hassle of keeping the thing up, backing-up the mailstore and so on; and because I was moving home, so I wanted a service that couldn't be knocked-out by the move. Not because of any deliverability issues. I haven't had deliverability issues since about 2010, and those were probably because I couldn't be bothered with DMARC.

My ISP is a niche outfit, targeted at nerds; their mailservers are Postfix/Dovecot, which suits me. They support Sieve, and they have a control panel with various knobs and buttons. As an ISP they're a bit pricey, but for email hosting they're cheap.

Re:Self-hosted email is the hardest it's ever been, but also... by gwd on Monday September 05, 2022 @03:45AM (#32721587)
One thing that was really buried in that article was this bit:

> At some point your IP range is bound to be banned, either by one asshole IP neighbor sending spam, one of your users being pwned [emphasis mine], due to arbitrary reasons, by mistake, it doesn't matter. It's not if, it's when.

In other words, at least some of the time, the one of his users' accounts had been compromised, and as a result, his servers were actually sending out spam. But rather than take responsibility for detecting and blocking outgoing spam on his own servers, he's blaming The System for doing exactly what it was meant to do.

Re:Self-hosted email is the hardest it's ever been, but also... by cm2187 on Monday September 05, 2022 @04:09AM (#32721726)
This exact thing happened to me. A test account I created with a weak password that I should have deleted but forgot about got pwned. I have spam detection in place and within an hour I disabled that account. But that was enough to send over 30,000 spam emails, and then your IP reputation is gone for a very long time.

The point being that outgoing spam detection won't save you, by the time you are pwned it's too late.

My solution is to have a script that scans the mail server log files and aggressively block ips of failed authentication attempts that are not quickly followed by a successful authentication attempt, and get immediate notification when there is a successful authentication attempt from an unexpected country (I think it's not the same bot that scans for vulnerable accounts and sends spam so you have maybe an hour to react).

That works well for a small user base.

Re:Self-hosted email is the hardest it's ever been, but also... by jelly on Monday September 05, 2022 @05:17AM (#32722138)
That sounds interesting, could you share the script?

I've encountered a few obvious login attempts like that, but since they come from a broad pool of IPs it's not something fail2ban can easily handle without collateral damage.

Re:Self-hosted email is the hardest it's ever been, but also... by cm2187 on Monday September 05, 2022 @07:00AM (#32722944)
It’s parsing smartermail logs which have a kind of funky format and the script quite tied to my setup (I have a central IP ban list because I also momitor non mail related protocols on multiple machines), so not sure it would be very useful to someone else.
Re:Self-hosted email is the hardest it's ever been, but also... by ixs on Monday September 05, 2022 @05:08AM (#32722074)
What I find so baffling is that these experiences do not match my own at all.

I've been running a non-profit ISP for about 23 years with a few friends. We've always been doing this from our own IP Space (/20) in RIPE. Even when we had problems sending spam (compromised user accounts, compromised php websites) and we ended up on a blacklist, we usually could get removed pretty fast.

For a few years our mail system would sometimes generate late-bounces, that is accept a mail on the incoming MX only to then figure out that it actually cannot be delivered later on and generate a delivery failure notification mail. Not a good situation.

That got us into some trouble here and there. But even that could easily be unblocked again.

When we finally managed to set up a new mail infrastructure (2 year project cause it's a hobby) we set up new outgoing SMTP servers which cycle through multiple IP addresses. There was exactly one ISP (Deutsche Telekom T-Online) that was not accepting mail from some of these IPs. One mail and a turnaround time of abour 12hrs later this was fixed. Gmail or Hotmail/live.com/Outlook never had any problems with deliverability. Even with a few users forwarding all their email to their gmail accounts including the spam that slips through our filters. That might mean that a single mail would not be deliverd, but other users never suffered as our outgoing IPs are not being blanket-banned.

There's one residential ADSL provider that has a blanket ban on one of our outgoing IPs. There's no way to get that resolved because their mail infrastructure is unmaintained and nobody is reading their mail. Common problem with that one ADSL provider, googling their name shows other people have the same problem. shrug We just use a different outgoing IP for them.

No DMARK or DKIM setup at all for outgoing mail.

So I wonder, what really makes the difference in experience? Is it just the fact that we have a decent sized IPv4 Network in our name as PI space?

Re:Self-hosted email is the hardest it's ever been, but also... by guerby on Monday September 05, 2022 @07:04AM (#32722970)
Ipv6 to the rescue with one IPv6 per email account in a /64?

:)