Archive for » July 19th, 2008«

SendMail Logger

This free cPanel sendmail logger is a WHM plugin that logs all mails sent through the server using the sendmail binary. You can see the logs in your WHM and identify spammers instantaneously

SendMail Logger Version: 1.0.0
P.S.: You will have to REGISTER for this copy to work. Registration is completely free, and this is included to keep our server bandwidth under control.
Download Now

Install Instructions:
PHP should be compiled with “Mail Headers”
cd /usr/src
chmod +x A-AST_sendmail_installer

Frequently Asked Questions:
1. What does the “Mail Header” do ?

It adds another field to your mails; something like this :
[Fri Jul 18 04:47:57 2005] [To: [email protected]] [Subject: Test mail]
[X-PHP-Script: for ] [from: [email protected]]
which makes it easy for you to identify who is sending the mails and using which script.

2. Okay, then why do I need your script ?

Good Question. Enabling “Mail Header” in PHP will send the above line to the recipient. This is awkward. As it is added as a header we cannot view it in the Exim mail logs. Only the recipient can view it. We can only know it when the header is sent back for tracing an abuse complaint usually to the Data Center (if the recipient does so). By this time we could be blocked for spamming or our IP can get null-routed.

Our SendMail Logger parses the header submitted by the mailer script, removes the line before passing the header to sendmail (original) and logs it.

Here is a sample:
Received: from nobody by with local (Exim 4.69)
(envelope-from )
id 1KJql4-0005nA-8W
for [email protected]; Fri, 18 Jul 2005 09:16:30 -0500
To: [email protected]
Subject: Test mail
X-PHP-Script: for
from: [email protected]
Date: Fri, 18 Jul 2005 09:16:30 -0500
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname – SERVER_NAME
X-AntiAbuse: Original Domain –
X-AntiAbuse: Originator/Caller UID/GID – [99 99] / [47 12]
X-AntiAbuse: Sender Address Domain – SERVER_NAME

On careful review you will notice that the line “X-PHP-Script: for ” is added by the “Mail Header”. Our script effectively removes this line from the recipient mail and logs it on your server, and you can check this from your WHM.

For Support and installation help, Please Open a ticket at :

P.S.: Standard Installation charges of 20 USD / hr applicable on installations by our support.

Developed By: AlFahed P M , Head-Operations, Admin-Ahead Server Technologies.