Attempting to use SourceBans' email system with webhost email account

Connect with other users about what to run on your webhosting (and how to run it) here.
Post Reply
User avatar
Niflheimrx
New to forums
New to forums
Posts: 4
https://www.youtube.com/channel/UC40BgXanDqOYoVCYFDSTfHA
Joined: Mon Nov 12, 2018 11:56 pm

Attempting to use SourceBans' email system with webhost email account

Post by Niflheimrx »

I am trying to setup the email system in SourceBans to allow players to submit ban protests forms through the website, and also allow creating new accounts through the SourceBans login system, however upon filling out the forms and testing out the system I am met with the error "Connection refused" upon attempting to send an email.

I have set the host to mail.nfoservers.com, with port 587 and SSL turned on. Username and Password fields are the same as my webhost email account credentials.

I realize automated emails are not allowed through the email accounts created through the NFo control panel, however it states that using the webhosting machine does allow automated emails so it should theoretically work. This instance of SourceBans is directly installed on my webhost machine.
User avatar
Edge100x
Founder
Founder
Posts: 13112
Joined: Thu Apr 18, 2002 11:04 pm
Location: Seattle
Contact:

Re: Attempting to use SourceBans' email system with webhost email account

Post by Edge100x »

Instead of using SMTP through mail.nfoservers.com, you need to use the local mail server. You can do this either through SMTP protocol (to localhost, port 25), through sendmail, or through another facility that your language may provide.
User avatar
Niflheimrx
New to forums
New to forums
Posts: 4
Joined: Mon Nov 12, 2018 11:56 pm

Re: Attempting to use SourceBans' email system with webhost email account

Post by Niflheimrx »

It appears that it is now able to send emails through the system!
However I am using my email address (that uses gmail) to send the emails and it appears that it is blocking emails to gmail. I did add an SPF record as instructed here: viewtopic.php?f=19&t=13682
Everytime I send an email it says that it failed to pass SPF checks since I have a hard fail policy. Not sure what is going on there
User avatar
Edge100x
Founder
Founder
Posts: 13112
Joined: Thu Apr 18, 2002 11:04 pm
Location: Seattle
Contact:

Re: Attempting to use SourceBans' email system with webhost email account

Post by Edge100x »

The outbound email may come from a different IP than you have in your policy, since it could come from another one attached to the webhosting VDS. You'll want to check the headers to see what IP it was received from and adjust the SPF policy to allow that IP.
User avatar
Niflheimrx
New to forums
New to forums
Posts: 4
Joined: Mon Nov 12, 2018 11:56 pm

Re: Attempting to use SourceBans' email system with webhost email account

Post by Niflheimrx »

That seemed to be the case, readjusting the SPF value to match the IP that was sending the email seems to have done the trick. Thank you for the help!
User avatar
Edge100x
Founder
Founder
Posts: 13112
Joined: Thu Apr 18, 2002 11:04 pm
Location: Seattle
Contact:

Re: Attempting to use SourceBans' email system with webhost email account

Post by Edge100x »

Great! Please note that you may need to continue to check on it occasionally. We will remove an old IP address from the machine hosting your website at the end of the month, for instance, and it could change again at that time.
Post Reply