Remove the X-GPG-Encrypt-Cc header setting.
I could not find any documention on this, it seems like this was a gpg-mailgate specific option but we now read in recipients directly from the command-line arguments.
This commit is contained in:
parent
cf79838484
commit
27e9d6ce50
1 changed files with 0 additions and 13 deletions
|
@ -30,11 +30,6 @@ raw_message = email.message_from_string( raw )
|
|||
from_addr = raw_message['From']
|
||||
to_addrs = sys.argv[1:]
|
||||
|
||||
encrypted_to_addrs = list()
|
||||
if raw_message.has_key('X-GPG-Encrypt-Cc'):
|
||||
encrypted_to_addrs.extend( [e[1] for e in email.utils.getaddresses([raw_message['X-GPG-Encrypt-Cc']])] )
|
||||
del raw_message['X-GPG-Encrypt-Cc']
|
||||
|
||||
def send_msg( message, recipients = None ):
|
||||
if recipients == None:
|
||||
recipients = to_addrs
|
||||
|
@ -90,14 +85,6 @@ keys = GnuPG.public_keys( cfg['gpg']['keyhome'] )
|
|||
gpg_to = list()
|
||||
ungpg_to = list()
|
||||
|
||||
for enc in encrypted_to_addrs:
|
||||
if enc in keys:
|
||||
gpg_to.append( (enc, enc) )
|
||||
elif cfg.has_key('keymap') and cfg['keymap'].has_key(enc):
|
||||
gpg_to.append( (enc, cfg['keymap'][enc]) )
|
||||
else:
|
||||
ungpg_to.append(enc)
|
||||
|
||||
for to in to_addrs:
|
||||
if to in keys:
|
||||
gpg_to.append( (to, to) )
|
||||
|
|
Loading…
Reference in a new issue