PHP mail() goes to junk, possible DNS issue?

无人久伴 提交于 2019-12-21 21:00:22

问题


I am sending a message via PHP's mail() with proper and complete headers. It has everything it is supposed to, and Hotmail likes the email itself. However, Hotmail is showing this in the source of the message:

X-DKIM-Result: None
X-Message-Status: n:0:n
X-SID-Result: None
X-AUTH-Result: NONE

I tried to get them to Pass but only managed to turn the SID and AUTH to "Fail" causing SmartScreen to see the message as suspicious and delete it after ten days, whereas before it just seemed like spam to the filters.

If I am able to get these to Pass, then the email will not be marked as junk. I know there's something I need to do in DNS. I have Reverse DNS set up on the website.

The email includes boundaries, MIME version, content type, reply-to and return-path, x-mailer etc. The content type is multipart/alternative (for the boundaries) and the subject nor body does not contain any spammy keywords.

Anyone know how to get these things to Pass via PHP or DNS?

Bottom line: If these results are "None" then it will just go to Junk peacefully. If they are "Fail" then it will be "suspicious" and automatically deleted. If they are "Pass" then it will go straight to inbox without a problem, but I don't know how to get them to Pass.

If it helps in any way, I am running Exim 4.77 on a cPanel/WHM (Linux) VPS. My IP address is clean and hasn't been abused in the past. It isn't blocked at any blacklists.


回答1:


Setup the SPF record in your DNS, can be a solution.

EDIT

Googling the message X-AUTH-Result: FAIL I found this post, that seem the same problem: https://serverfault.com/questions/138886/emails-going-to-junk-for-hotmail-recipients




回答2:


Make sure the server the mail is being sent from has a proper rDNS or PTR record back to it's hostname.



来源:https://stackoverflow.com/questions/11280030/php-mail-goes-to-junk-possible-dns-issue

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!