Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

mail bcc recipients #7

mmerickel opened this Issue · 3 comments

3 participants

Michael Merickel Marcin Kuźmiński Chris McDonough
Michael Merickel

According to mitchell` on #pyramid, there may be an issue sending mail to BCC recipients.

Marcin Kuźmiński

I can confirm there is a problem with BCC:

Tested on my app, I'd put CC and BCC (and different variations of it)

Mails get delivered to both cc or BCC but BCC is visible in the email header and can be read.

Here's the header of email I'd received

From: errors@****.com
Subject: test
To: marcin@****.com, marcin@*****.com
Michael Merickel
Marcin Kuźmiński

The issue here is that the code adds bcc: header into the email, that is not correct. SMTP headers are really just for email clients, thus adding bcc header makes it visible in email clients.

The fix to this issue is to remove Bcc from ADDRESS_HEADERS_WHITELIST, and

        if self.bcc:
            response.base['Bcc'] = self.bcc

in get_response function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.