I am trying to send mail using PHP mail function and sendmail on RHEL. There is a line in the header, Received: (from apache@localhost), which is causing some recipients to drop the message. I need to get this portion of the header replaced with a proper user/domain: (lets say user@example.com). I have been fighting with this for a while, I am just not sure what to do. Discussions are just all over the place on the web. The scripts do specify the sender.
Here is an example of the SMTP header:
Received: from <omitted> (<omitted> [127.0.0.1])
by <omitted> (8.14.4/8.14.4) with ESMTP id rADEwvp4003653
for <omitted>; Wed, 13 Nov 2013 09:58:57 -0500
Received: (from apache@localhost)
by <omitted> (8.14.4/8.14.4/Submit) id rADEwvEj003650;
Wed, 13 Nov 2013 09:58:57 -0500
Date: Wed, 13 Nov 2013 09:58:57 -0500
Message-Id: <omitted>
To: <omitted>
Subject: <omitted>
From: user@example.com
Reply-To: user@example.com