How to find sending spam emails and enable mail header in php.ini

- In Linux servers if there are a lot of emails in the queue "over 100" emails. you can check if there is a spam

~#exim -bp

To get a list of emails that are in the queue

~#exim -Mvh MessageID

Will display the message content and by checking the field "auth_id" in the header you can identify the email account that sending spam. if this field does not exist i the header, you can enable it be adding mail header in php.ini as follows:

mail.add_x_header = On

And mail log as follows:

mail.log = /var/log/phpmail.log


More usefull information can be found on the link below on how mail works:

http://www.physics.udel.edu/~bnikolic/teaching/phys660/RUTE/rute/node33.html
 
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How To: Back Up MySQL Databases From The Command Line

While automated backups are important, sometimes you just want to take a quick and dirty snapshot...

How To Install MariaDB on CentOS 6

MariaDB is a drop-in replacement for MySQL. It is easy to install, offers many speed and...

How to Display (List) All Jobs in Cron / Crontab

View Root’s Cron Jobs crontab -l  View a User’s Cron Jobs crontab -u username -l Example with...

How To: Automate Server Scripts With Cron

Servers can automatically perform tasks that you would otherwise have to perform yourself, such...

Install memcache

Step 1: Login into your WHM panel and using easyapache enable Memcache Step 2: SSH into...