Please don't make unfounded legalistic demands (was: [a, b, c, d] = 1, 2, 3, 4)

Andy Kubiak andy.kubiak at gmail.com
Wed Aug 26 14:11:34 EDT 2015


>
> I wish I could, problem is, if the mail recipient is within the company,
> no legal boilerplate is added making the joke fall flat.
>

What if you could send all your mail to another address on a server you
control, or can at least run programs on?

Could you configure all your outgoing mail to include the actual recipient
list in brackets in the subject line, rather than in the "To:" field?

So, your outgoing SMTP message, instead of looking like:
"From: jeanmichel at sequans.com
To: Foo Barbaz <f.barbaz at foobarbaz.com>, python-list at python.org
Subject: Please don't make blahblahblah
I wish I could, but I can't, ergo I won't

TOP SECRET EMAIL MESSAGE WITH DIRE CONSEQUENCES FOR WANDERING EYES"

might look more like:
"From: jeanmichel at sequans.com
To: otheremailaddress at serveryoucontrol_or_canatleastrunprogramson.com
Subject: [Foo Barbaz <f.barbaz at foobarbaz.com>, python-list at python.org]
Please don't make blahblahblah
I wish I could, but I can't, ergo I won't

TOP SECRET EMAIL MESSAGE WITH DIRE CONSEQUENCES FOR WANDERING EYES"?

Then could you use pass the message through a script that uses
email.message_from_string()
<https://docs.python.org/3/library/email.parser.html#email.message_from_string>
to create an <email.message> object, remove the delivery cruft by calling
<email.message>.__delitem__('Received') on it, recreate the actual "To:"
field with some to_list = [email.utils.parseaddr
<https://docs.python.org/3/library/email.util.html>(x) for x in
string_in_brackets_in_subject] hackery, do a quick

strained_string = re.sub <https://docs.python.org/3/library/re.html>('TOP
SECRET EMAIL MESSAGE WITH DIRE CONSEQUENCES FOR WANDERING EYES', '',
<modifed.email.message>.as_string())?

Could you then send that off?




This is not a privileged message. If you're reading this, it could be
because this is just a text file without any implied security or privacy
capacity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20150826/dd21cdb0/attachment.html>


More information about the Python-list mailing list