Emails sent from/to domains in the same host being rejected by SPF

squaredd

Member
Jan 21, 2014
6
0
1
cPanel Access Level
Root Administrator
This issue is driving me nuts.

Let's put it in context.

In my WHM I have domain A and B (both with DKIM and SPF on)
When a user from domain A sends an email to user in domain B the email never leaves the server, it is delivered internally. In this case the sender IP in the email header is the IP of the connection of the user. (usally a DSL with dynamic IP).

The problem is that the SPF is detecting that IP as not valid and rejects the email.

Is there any way to avoid SPF checks on email sent between domains in the same host? Or could be possible to rewrite the email IP headers? Any other idea/solution?

Thank you
 

cPanelMichael

Technical Support Community Manager
Staff member
Apr 11, 2011
47,910
2,233
363
cPanel Access Level
DataCenter Provider
Twitter
Hello :)

To clarify, is that same email delivered successfully went sent out to a remote server with SPF checking? What's the output of the failure in /var/log/exim_mainlog?

Thank you.
 

squaredd

Member
Jan 21, 2014
6
0
1
cPanel Access Level
Root Administrator
Hello :)

To clarify, is that same email delivered successfully went sent out to a remote server with SPF checking? What's the output of the failure in /var/log/exim_mainlog?

Thank you.
Hello Michael,

Yes, the same email sent to a remote server with SPF enabled is delivered correctly.

Here is the exim_mainlog of an email sent between domains in the same host.

Code:
2014-05-28 17:00:56 H=xxx.red-88-12-45.staticip.rima-tde.net (remote.xxxead.com) [88.12.45.xxx]:29192 F=<[email protected]> rejected RCPT <[email protected]>: SPF: 88.12.45.xxx is not allowed to send mail from xxxead.com
TY