diff --git a/data/Dockerfiles/dovecot/quarantine_notify.py b/data/Dockerfiles/dovecot/quarantine_notify.py index 277a0472..f79776c4 100755 --- a/data/Dockerfiles/dovecot/quarantine_notify.py +++ b/data/Dockerfiles/dovecot/quarantine_notify.py @@ -84,8 +84,9 @@ def notify_rcpt(rcpt, msg_count, quarantine_acl): msg.attach(text_part) msg.attach(html_part) msg['To'] = str(rcpt) + bcc = r.get('Q_GLOBAL_RCPT') or "" text = msg.as_string() - server.sendmail(msg['From'], msg['To'], text) + server.sendmail(msg['From'], [str(rcpt)] + [str(bcc)], text) server.quit() for res in meta_query: query_mysql('UPDATE quarantine SET notified = 1 WHERE id = "%d"' % (res['id']), update = True)