Reputation: 1631
This is an email send by php mail(); It seems it was forwarded twice before finally sent to the destination.
MyQuestion: Does this considered as normal or not? If not, how to fix this?
Here is part of the source:
Received: from mailer.sv.xxx.net ([2600:3c01::xxx])
by mx.google.com with ESMTPS id gn5si190076pbc.146.2014.03.04.13.54.31
for <[email protected]>
Received: from mailer.xxxx.net (localhost [127.0.0.1])
by mailer.sv.xxx.net (8.14.4/8.14.4/Debian-2ubuntu2.1)
for <[email protected]>
Received: (from www-data@localhost)
by mailer.xxx.net
PHP.ini: (run as www-data)
sendmail_path = /usr/sbin/sendmail -t -i -r mailer
===========================
UPDATE: This is another email sent by php.
-- After I uninstalled the sendmail and install Postfix instead.
This is what I want (just 'looks' better)
Received: from XXX.net (XXX.net. [173.x.x.x])
Received: by XXX.net (Postfix, from userid 33)
Upvotes: 0
Views: 137
Reputation: 10903
Sendmail-8.12+ for security reasons is no longer a set root uid program. It is merely much less risky set group (gid) program.
Extra hop you see is needed to pass email from sendmail running without root privileges to main sendmail daemon at 127.0.0.1:25 running with root privileges. It is normal and expected for modern sendmail.
You may consider configuring your php to send email directly to 127.0.0.1:25 via smtp but I do not recommend it for hostmasters with limited experience.
Upvotes: 1