diff options
Diffstat (limited to 'src/mailman_pgp/workflows/key_change.py')
| -rw-r--r-- | src/mailman_pgp/workflows/key_change.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mailman_pgp/workflows/key_change.py b/src/mailman_pgp/workflows/key_change.py index c6d3ebc..cc5b9fc 100644 --- a/src/mailman_pgp/workflows/key_change.py +++ b/src/mailman_pgp/workflows/key_change.py @@ -28,6 +28,7 @@ from zope.interface import implementer from mailman_pgp.database import transaction from mailman_pgp.model.address import PGPAddress +from mailman_pgp.model.list import PGPMailingList from mailman_pgp.pgp.utils import copy_headers from mailman_pgp.pgp.wrapper import PGPWrapper @@ -58,6 +59,7 @@ class KeyChangeWorkflow(Workflow): def __init__(self, mlist, pgp_address=None, pubkey=None): super().__init__() self.mlist = mlist + self.pgp_list = PGPMailingList.for_list(mlist) self.pgp_address = pgp_address self.pubkey = pubkey @@ -104,7 +106,7 @@ class KeyChangeWorkflow(Workflow): self.pubkey.fingerprint, self.token)) wrapped = PGPWrapper(msg) - encrypted = wrapped.encrypt(self.pubkey) + encrypted = wrapped.sign_encrypt(self.pgp_list.key, self.pubkey) msg.set_payload(encrypted.get_payload()) copy_headers(encrypted, msg, True) |
