cancel
Showing results for 
Search instead for 
Did you mean: 

Hosting an SMTP server - info on Spamhaus PBL and relays?

HeuristicToaste
Newbie
Posts: 7
Registered: ‎21-03-2016

Hosting an SMTP server - info on Spamhaus PBL and relays?

Hi! Not 100% sure if this is the correct place to ask, but I was directed here from a Live Chat and it seems as good a place as any.
I've got a domain that I'd like to use email with, but I don't really want to pay quite a significant amount per GB per mailbox per month for my registrar to host it for me.
It would seem the best plan is to just host it myself, because then I get the benefits of running something like Sieve to sort my mail for me and server-side PGP, not to mention unlimited domains, accounts, bandwidth and storage.
So, as an experiment I set up a Postfix / Dovecot server and am currently able to use it to receive mail from anywhere and send internal emails (from and to the same domain). Unfortunately, my IP is of course on the Spamhaus PBL so I can't send emails to anyone on a different domain.
Spamhaus themselves recommend using an SMTP relay server (http://bit.ly/1Rwd5sf), specifically "use your ISP's outgoing mail relay as a 'smarthost' [if they support it]". I've found this: http://www.plus.net/support/email/smtp_mail.shtml which appears to be related, but not quite what I'm after. So - does anybody here know about whether Plusnet has a mail relay server I can use, and if not what services are out there that can provide something similar? Is it inadvisable to get a static IP and request the IP is removed from the PBL?
Thanks for any help!
8 REPLIES 8
bobpullen
Community Gaffer
Community Gaffer
Posts: 16,887
Thanks: 4,979
Fixes: 316
Registered: ‎04-04-2007

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

I'd suggest smart hosting via our relays - relay.plus.net. Static IP is the other route but is probably more hassle.

Bob Pullen
Plusnet Product Team
If I've been helpful then please give thanks ⤵

SteveA
Pro
Posts: 1,847
Thanks: 106
Fixes: 3
Registered: ‎17-06-2007

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

I use Plusnet for my outgoing relay.
So for Postfix this is :
relayhost = relay.plus.net
Also don't forget to set mydestination  and mynetworks which stops you being used as a relay



HeuristicToaste
Newbie
Posts: 7
Registered: ‎21-03-2016

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

Thanks a lot, guys - sorry for not replying sooner
I made sure to set relayhost and mydestination when I was setting the server up, but a good point nonetheless!
I thought there would be more to it than that regarding authenticating relay.plus.net to send my mail for my domain, but I guess not.
Could I quickly ask, what kind of protection can be set up to prevent others masquerading as myself?
At the moment, 100% of what I have done is server-side, which is to say I haven't at any point had to touch my MX or SPF records, and yet I can now send mail as me@mydomain.com.
I was under the impression SPF records acted like whitelists, but as far as I can tell I can just change my Postfix config and start sending mail as notme@abankorsomething.com 😕
Am I missing something obvious?
HeuristicToaste
Newbie
Posts: 7
Registered: ‎21-03-2016

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

I can't edit my previous post, so here's an update:
My test emails were being caught by the MTAs as not matching the SPF record for my domain, but the were just choosing to ignore it. Using DMARC records I can now instruct the MTAs to reject any emails violating the SPF record, which is good - but there's still a problem. Plusnet's relay is now in my SPF record, meaning anybody with Plusnet as an ISP can send emails via relay.plus.net as me@mydomain.com, which is less than the whole internet but still a sizeable chunk of it.
So, do you know if there is a way to tell relay.plus.net to only relay mail for *@mydomain.com if it comes from an IP matching my domain's A record, like SPF but one that only relay.plus.net uses?
Cheers!
bobpullen
Community Gaffer
Community Gaffer
Posts: 16,887
Thanks: 4,979
Fixes: 316
Registered: ‎04-04-2007

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

Quote from: HeuristicToaster
So, do you know if there is a way to tell relay.plus.net to only relay mail for *@mydomain.com if it comes from an IP matching my domain's A record, like SPF but one that only relay.plus.net uses?

I don't believe this is possible. Our servers will relay mail from any domain with valid MX records. It's highly unlikely anybody else is going to be using our relay servers to send messages from your domain though.

Bob Pullen
Plusnet Product Team
If I've been helpful then please give thanks ⤵

Andrue
Pro
Posts: 775
Thanks: 90
Fixes: 1
Registered: ‎12-01-2015

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

Unfortunately, my IP is of course on the Spamhaus PBL so I can't send emails to anyone on a different domain.

 

Why 'of course'? Seems a bit odd to me.

 

Anyway I run a mail server from home and setting it up was easy.

  • Installed the software (VPOP3) on my Windows server (XP originally I think, now Win 7).
  • Forward the various ports on my router to the server.
  • Created the MX record.
  • Create an SPF record (optional for IPv4 but GMail needs it for IPv6 should you happen to be on a good ISP that offers that protocol as I once was).
  • Ask ISP to set up reverse DNS.

I've been running it for several years now across three different ISP's networks. I've never needed to rely on their servers for relaying.

Saltee
Dabbler
Posts: 17
Registered: ‎19-11-2015

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

 

I host my own MTA at home (using sendmail) with a fixed IP from PlusNet and have never had any issues, it was hosted on a BE fixed address previously.  I don't use SMTP forwarding.  One thing to make sure of is that your local DNS is in order as well as SPF (and DKIM if you can be bothered) - a lot of MTA's will drop/reject mail if these are not configured (i.e. you can't prove who you are).

You might be interested in this site, http://www.mail-tester.com/  it scores your mail and shows the most common ipv4 blacklists and whether you're on them.  Hats off to the guys and gals that host it, most useful.

Good Luck.

 

 

Make sure,

 

corringham
Seasoned Champion
Posts: 1,232
Thanks: 650
Fixes: 16
Registered: ‎25-09-2015

Re: Hosting an SMTP server - info on Spamhaus PBL and relays?

I've also hosted my own mail server for well over a decade on various ISPs. I use Postfix/Dovecot on Linux, and actually support half a dozen domains with several dozen users and >50 active e-mail accounts (on Plusnet ADSL Max). I don't use Plusnet's relays, as relays just add unpredictable delays - people usually receive e-mails I send within a couple of seconds. I've very rarely have had any problems - and those I've had have usually been due to other mail servers going wrong!

You do need a fixed IP, and correct MX and SPF records, and ideally reverse DNS set to your domain.