Question

How to hide my DO ip address in received gmail headers?

Posted December 13, 2013 4.6k views
Hi...i'm using msmtp sendmail service, How to hide my DO ip address in received gmail headers? Thanks! Received: from localhost ([my DO ipaddress]) >https://www.digitalocean.com/community/articles/how-to-use-gmail-or-yahoo-with-php-mail-function

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

4 answers
Did you restart apache2?
sudo service apache2 restart
Yes i did it, restarted, trying two new user registration, but all the notification email headers in mysecond@gmail.com and mythird@gmail.com still the same:

Delivered-To: mysecond@gmail.com
Received: by [notmydropletip] with SMTP id xxxxxx
X-Received: by [notmydropletip] with SMTP id xxxxxx
Return-Path:
Received-SPF: neutral ...
Authentication-Results: mx.google.com...
Received: from localhost ([xxx.xxx.xxx.xxx]) by mx.google.com with ESMTPSA id xxxxxx
To: mysecond@gmail.com
Subject: [inamasei.com] New User Registration

I don't think there is any way to hide it since Gmail passes it over. You can try using a SMTP service such as mandrillapp.com (edit msmtp's config to match your mandrill account's SMTP credentials).
I wonder if this issue is tangentially-related (i.e. the /etc/hosts file) to the problem being addressed, here: Email sent to gmail is flagged as spam?
Submit an Answer