1

Topic: Trying to "monitor incoming or outgoing mails with BCC "

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.1
- Deployed with iRedMail Easy or the downloadable installer? downloadable
- Linux/BSD distribution name and version: Ubuntu 18.04lts
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): mysql
- Web server (Apache or Nginx):nginx
- Manage mail accounts with iRedAdmin-Pro? no
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

Hello everybody,

I am testing iredmail and trying to setup the Monitor incoming and outgoing mail with bcc option.
My problem is that i could not make the incoming option to work.
First, the outgoing part is working fine. I tried these two alternatives for sender_bcc_user tables with success:

THIS WORKS. When test@kakata.com send an email the destination receive it and bcc_address in the table receive its copy. Excellent.
Option 1.
MariaDB [vmail]> select * from sender_bcc_user;
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+
| username        | bcc_address       | domain     | created             | modified            | expired             | active |
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+
| test@kakata.com | testxx@kakata.com | kakata.com | 2020-03-11 19:42:40 | 1970-01-01 01:01:01 | 9999-12-31 00:00:00 |      1 |
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+
Option 2.
MariaDB [vmail]> select * from sender_bcc_user;
+-----------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| username        | bcc_address      | domain     | created             | modified            | expired             | active |
+-----------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| test@kakata.com | testxx@gmail.com | kakata.com | 2020-03-11 19:42:40 | 1970-01-01 01:01:01 | 9999-12-31 00:00:00 |      1 |
+-----------------+------------------+------------+---------------------+---------------------+---------------------+--------+

But for recipient_bcc_user table, nothing seems to work. I tried these two options for recipient_bcc_user table:
When some email is sent to text@kakata.com, testxx does not receive a copy of the email.
Option 1.
MariaDB [vmail]> select * from recipient_bcc_user;
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| username         | bcc_address      | domain     | created             | modified            | expired             | active |
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| test@kakata.com  | testxx@gmail.com | gmail.com  | 2020-03-11 19:44:53 | 1970-01-01 01:01:01 | 9999-12-31 00:00:00 |      1 |
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
Option 2. (doesn't work neither)
MariaDB [vmail]> select * from recipient_bcc_user;
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+
| username        | bcc_address       | domain     | created             | modified            | expired             | active |
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+
| test@kakata.com | testxx@kakata.com | kakata.com | 2020-03-11 19:44:53 | 1970-01-01 01:01:01 | 9999-12-31 00:00:00 |      1 |
+-----------------+-------------------+------------+---------------------+---------------------+---------------------+--------+

What i'm doing wrong? Any ideas?

Regards,

Carlos

2

Re: Trying to "monitor incoming or outgoing mails with BCC "

Please show us related Postfix log while you sending email to trigger the recipient bcc.

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee

3

Re: Trying to "monitor incoming or outgoing mails with BCC "

Hello ZhangHuangbin,

Thank you for your support.

This is the /var/log/mail.log

Mar 16 11:10:05 mx amavis[1139]: starting. /usr/sbin/amavisd-new at mx.kakata.com amavisd-new-2.11.0 (20160426), Unicode aware, LC_ALL="C", LANG="en_US.UTF-8"
Mar 16 11:10:08 mx amavis[1954]: Net::Server: Group Not Defined.  Defaulting to EGID '121 121'
Mar 16 11:10:08 mx amavis[1954]: Net::Server: User Not Defined.  Defaulting to EUID '117'
Mar 16 11:10:09 mx amavis[1954]: No ext program for   .F, tried: unfreeze, freeze -d, melt, fcat
Mar 16 11:10:09 mx amavis[1954]: No ext program for   .zoo, tried: zoo, unzoo
Mar 16 11:10:09 mx amavis[1954]: No decoder for       .F
Mar 16 11:10:09 mx amavis[1954]: No decoder for       .zoo
Mar 16 11:10:09 mx amavis[1954]: Using primary internal av scanner code for clamav-socket
Mar 16 11:10:09 mx amavis[1954]: Found secondary av scanner clamav-clamscan at /usr/bin/clamscan
Mar 16 11:10:14 mx postfix/postfix-script[2381]: starting the Postfix mail system
Mar 16 11:10:15 mx postfix/master[2390]: daemon started -- version 3.3.0, configuration /etc/postfix
Mar 16 11:10:15 mx fetchmail[2481]: starting fetchmail 6.3.26 daemon
Mar 16 11:12:31 mx fetchmail[2481]: 1 message for dummy@kakata.com at pop.readyhosting.com (3685 octets).
Mar 16 11:12:34 mx fetchmail[2481]: reading message dummy@kakata.com@pop.readyhosting.com:1 of 1 (3685 octets) flushed

My /etc/fetchmailrc is:
set postmaster "postmaster@kakata.com"
set no bouncemail
set showdots
set properties ""
set daemon 60

poll "pop.readyhosting.com" with protocol pop3
user "dummy@kakata.com" pass "DUMMYpass123" is "dummy@kakata.com" smtphost "/var/run/dovecot/lmtp"

Current recipients_bcc_user table:
MariaDB [vmail]> select * from recipient_bcc_user;
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| username         | bcc_address      | domain     | created             | modified            | expired             | active |
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
| dummy@kakata.com | crpe00@gmail.com | kakata.com | 2020-03-11 19:44:53 | 1970-01-01 01:01:01 | 9999-12-31 00:00:00 |      1 |
+------------------+------------------+------------+---------------------+---------------------+---------------------+--------+
1 row in set (0.00 sec)

Regards,
Carlos

4

Re: Trying to "monitor incoming or outgoing mails with BCC "

Please try to send an email to dummy@kakata.com and show us related Postfix log for troubleshooting.

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee