Blind Copy BCC Outgoing eMail Using Exim

Issue: Client requires outgoing email from a specific account to be blind copied to another account. Server is CentOS based, using cPanel, and Exim.

Solution: Create and edit a custom Exim filter file.

Copy the existing Exim system filter file:

cp /etc/cpanel_exim_system_filter /etc/cpanel_exim_system_filter_custom

Edit /etc/exim.conf.localopts to point to the new file you just created (cpanel_exim_system_filter_custom)

nano /etc/exim.conf.localopts

and change the “systemfilter” parameter to read as:

systemfilter=/etc/cpanel_exim_system_filter_custom

Add the directives to the new system filter file (cpanel_exim_system_filter_custom)

nano /etc/cpanel_exim_system_filter_custom

and add using the following syntax example below:

if $sender_address_domain is sending-account@yourdomain.com
then
unseen bcc-receiving-account@yourdomain.com
endif

Change “sending-account@yourdomain.com” to the actual email account that is used to send email..
Change “bcc-receiving-account@yourdomain.com” to the actual email account that you want the Bcc’d email to be copied (sent) to.

Rebuild Exim:

/scripts/buildeximconf

Restart Exim:

service exim restart

eMail sent by sending-account@yourdomain.com will be blind copied Bcc’d to bcc-receiving-account@yourdomain.com

Note: If for some reason there is no /etc/exim.conf.local file, then log into WHM >> Exim Configuration Editor >> Advanced Editor and save the file (don’t make any changes). That should create the initial exim.conf.local file

Leave a comment

BlogLogistics