DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD Ports and Packages

FreeBSD Ports and Packages Installation and upgrading of ports and packages on FreeBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 4th November 2008
DNAeon DNAeon is offline
Shell Scout
 
Join Date: Sep 2008
Location: Bulgaria
Posts: 138
Default Qmail and setting IP of the sender...

Hi!

I've noticed that my qmail server is not working right.. I've googled around, but didn't find the answer so I'm asking you for help..

I've a forum where when a user registers they have to validate their registration through the e-mail sent to them by the qmail server. But that's not the problem.

The mail server is behind a firewall.

The problem is with gmail.com - I have to put some extra elements in the email header - probably X-Originating-IP, because when I send a message to gmail.com the message is being kept in the SPAM folder. Maybe something with rDNS?

This is mail header:
Code:
Return-Path: <daemon@unix-heaven.org>
Delivered-To: unix-heaven.org-daemon@unix-heaven.org
Received: (qmail 17077 invoked by uid 80); 4 Nov 2008 09:49:27 +0200
To: "=?UTF-8?B?dGVzdGluZw==?=" <daemon@unix-heaven.org>
Subject: =?UTF-8?B?0JTQvtCx0YDQtSDQtNC+0YjQu9C4INCyICJ3d3cudW5peC1oZWF2ZW4ub3JnIg==?=
From: <daemon@unix-heaven.org>
Reply-To: <daemon@unix-heaven.org>
Sender: <daemon@unix-heaven.org>
MIME-Version: 1.0
Message-ID: <a7cf86a81cb41c6945a34b6e54ace046@www.unix-heaven.org>
Date: Tue, 04 Nov 2008 09:49:26 +0200
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: PhpBB3
X-MimeOLE: phpBB3
X-phpBB-Origin: phpbb://unix-heaven.org/forums
X-AntiAbuse: Board servername - www.unix-heaven.org
X-AntiAbuse: User_id - 1
X-AntiAbuse: Username - Anonymous
X-AntiAbuse: User IP - 213.222.47.97
I'm missing something here, but what?

Thanks for any help!
__________________
"I never think of the future. It comes soon enough." - A.E

Useful links: FreeBSD Handbook | FreeBSD Developer's Handbook | The Porter's Handbook | PF User's Guide | unix-heaven.org
Reply With Quote
  #2   (View Single Post)  
Old 4th November 2008
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,125
Default

Reverse DNS is not the issue
Code:
$ dig  +short unix-heaven.org    
78.90.73.87

$ dig  +short -x 78.90.73.87    
unix-heaven.org.
I wonder what kind of header you posted A header of spam message received by Gmail looks like this
Code:
Delivered-To: pietjepuk@gmail.com
Received: by 10.114.151.3 with SMTP id y3cs187278wad;
        Tue, 4 Nov 2008 15:17:48 -0800 (PST)
Received: by 10.214.95.39 with SMTP id s39mr183633qab.386.1225840667434;
        Tue, 04 Nov 2008 15:17:47 -0800 (PST)
Return-Path: <MamiebehalfPierre@breitbart.com>
Received: from supersof2fa61c ([119.73.111.147])
        by mx.google.com with SMTP id 2si1177262qyk.84.2008.11.04.15.17.43;
        Tue, 04 Nov 2008 15:17:47 -0800 (PST)
Received-SPF: neutral (google.com: 119.73.111.147 is neither permitted nor denied by best guess record for domain of MamiebehalfPierre@breitbart.com) client-ip=119.73.111.147;
Authentication-Results: mx.google.com; spf=neutral (google.com: 119.73.111.147 is neither permitted nor denied by best guess record for domain of MamiebehalfPierre@breitbart.com) smtp.mail=MamiebehalfPierre@breitbart.com
Received: (from tomcat@localhost)
	by 105.120.186.176 (8.12.8/8.12.8/Submit) id j6CHmn3V903716
	for pietjepuk@gmail.com; Tue, 4 Nov 2008 16:16:44 +0800
Date: Tue, 4 Nov 2008 16:16:44 +0800
Message-ID: <442p730s.4904410@breitbart.com>
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump
Reply With Quote
  #3   (View Single Post)  
Old 5th November 2008
DNAeon DNAeon is offline
Shell Scout
 
Join Date: Sep 2008
Location: Bulgaria
Posts: 138
Default

Actually, this is the right header which is being sent to gmail.com

Code:
Delivered-To: testing.uh@gmail.com
Received: by 10.187.217.11 with SMTP id u11cs292153faq;
        Tue, 4 Nov 2008 04:23:45 -0800 (PST)
Received: by 10.86.70.3 with SMTP id s3mr1135787fga.25.1225801425483;
        Tue, 04 Nov 2008 04:23:45 -0800 (PST)
Return-Path: <daemon@unix-heaven.org>
Received: from unix-heaven.org (unix-heaven.org [78.90.73.87])
        by mx.google.com with ESMTP id 12si10003041fgg.0.2008.11.04.04.23.44;
        Tue, 04 Nov 2008 04:23:45 -0800 (PST)
Received-SPF: pass (google.com: best guess record for domain of daemon@unix-heaven.org designates 78.90.73.87 as permitted sender) client-ip=78.90.73.87;
Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of daemon@unix-heaven.org designates 78.90.73.87 as permitted sender) smtp.mail=daemon@unix-heaven.org
Received: (qmail 19857 invoked by uid 80); 4 Nov 2008 14:23:59 +0200
To: "=?UTF-8?B?dGVzdGluZw==?=" <testing.uh@gmail.com>
Subject: =?UTF-8?B?0JTQvtCx0YDQtSDQtNC+0YjQu9C4INCyICJ3d3cudW5peC1oZWF2ZW4ub3JnIg==?=
From: <daemon@unix-heaven.org>
Reply-To: <daemon@unix-heaven.org>
Sender: <daemon@unix-heaven.org>
MIME-Version: 1.0
Message-ID: <8463899dd32614a8d7d9b18867714ec5@www.unix-heaven.org>
Date: Tue, 04 Nov 2008 14:23:59 +0200
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: PhpBB3
X-MimeOLE: phpBB3
X-phpBB-Origin: phpbb://unix-heaven.org/forums
X-AntiAbuse: Board servername - www.unix-heaven.org
X-AntiAbuse: User_id - 2
X-AntiAbuse: Username - daemon
X-AntiAbuse: User IP - 213.222.47.97
I have several machines behind the firewall, and they are nat-ted with several IPs. I noticed that the web-server was nat-ted with a wrong IP, but now I fixed that, and this is the header of the message now.

I've created another gmail account, but still the message goes to SPAM. I've read somewhere that gmail, yahoo and AOL are using some kind of spam fighting where the message header should contain also X-Originating-IP and there's a patch for the qmail, but I have to recompile everything in order to apply the patch..

Isn't there another way to fix this?

Thanks!
__________________
"I never think of the future. It comes soon enough." - A.E

Useful links: FreeBSD Handbook | FreeBSD Developer's Handbook | The Porter's Handbook | PF User's Guide | unix-heaven.org
Reply With Quote
  #4   (View Single Post)  
Old 6th November 2008
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,125
Default

You could just start with adding a SPF record in the DNS for unix-heaven.org. See http://en.wikipedia.org/wiki/Sender_Policy_Framework.

The OpenSPF website http://www.openspf.org/ has a form you can fill in. Based on the information you enter, it will create a SPF record, which you can enter into the DNS records for your site.
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump

Last edited by J65nko; 28th December 2009 at 08:58 AM. Reason: tag typo
Reply With Quote
  #5   (View Single Post)  
Old 6th November 2008
DNAeon DNAeon is offline
Shell Scout
 
Join Date: Sep 2008
Location: Bulgaria
Posts: 138
Default

Hi, J65nko!

Thanks for your help!

I've got another question.. Do I have to run a DNS server in order to enter the SPF record? All I have is a web server and a mail server.
__________________
"I never think of the future. It comes soon enough." - A.E

Useful links: FreeBSD Handbook | FreeBSD Developer's Handbook | The Porter's Handbook | PF User's Guide | unix-heaven.org
Reply With Quote
  #6   (View Single Post)  
Old 6th November 2008
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,125
Default

You don't have to run a DNS server yourself, all that is needed to have access to the specific nameserver that is publishing your DNS records.

In most case the "control panel" of your web hosting company gives such access.
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Discussion on MTA : SendMail, Postfix, Exim, Qmail aleunix General software and network 35 13th February 2009 04:23 PM
qmail scanner problem t4y4n FreeBSD General 1 5th August 2008 07:36 PM
sendmail vs qmail vs postfix vs exim graudeejs General software and network 6 22nd July 2008 03:25 PM
Setting Up MPD benjgvps FreeBSD General 0 21st May 2008 12:20 PM
thanks for setting this up DraconianTimes Off-Topic 8 5th May 2008 08:14 AM


All times are GMT. The time now is 06:23 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick