SMimeSigner policy

Created on 29 September 2023, over 1 year ago

Looking at policy options, feels like adding crypto to support something that was currently available in Swiftmailer would be useful to send email using a certificate

Symfony doc : https://symfony.com/doc/current/mailer.html#s-mime-signer

✨ Feature request
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada kiwad

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @kiwad
  • πŸ‡¬πŸ‡§United Kingdom adamps

    Good idea. In addition to S/MIME signing could also include DKIM signing and encrypting.

  • πŸ‡«πŸ‡·France nicodh

    Hi,

    I attach a patch with following changes :

    • Introduces a new EmailAdjuster plugin: DkimSignerAdjuster, with configurable domain / selector and keys generation / DNS information
    • Add a pre-send phase (needed to allow changes directly on fully-prepared symfony email, as described by symfony mailer's DkimSigner documentation)
    • Introduces a new SigningHelper service (to factor methods like keys discovery/generation)
  • πŸ‡«πŸ‡·France nicodh

    Fix configuration variables + improve dkim keys informations

  • Status changed to Needs review about 1 year ago
  • πŸ‡«πŸ‡·France nicodh

    Could someone review this code?
    It concerns only DKIM signing, but could be useful and merged IMHO (more and more email providers block unsigned emails).

  • πŸ‡«πŸ‡·France nicodh

    After testing on another project, I add test for DKIM domain on plugin's settings form.

  • πŸ‡­πŸ‡ΊHungary mxr576 Hungary

    I found this issue when I proposed a similar feature for a friendly module in the neighborhood and I think it worth mentoining it seems that the Symfony Mailer library may have a built-in event to add this feature: https://www.drupal.org/project/symfony_mailer_lite/issues/3424075#commen... ✨ Add support form DKIM signing Active

    I haven't checked yet what other possibilities are available in this module.

  • πŸ‡«πŸ‡·France nicodh

    Thanks @mxr576 for this. Could you try this module with #7 patch to confirm that it works ?

  • Status changed to RTBC 15 days ago
  • πŸ‡§πŸ‡ͺBelgium jeroenbegyn

    I have tested this patch and it works. The patch applies and DKIM validation passes.

  • Tested patch #7
    Applies and works for me!

  • πŸ‡¬πŸ‡§United Kingdom adamps

    Great that the patch is working for some people. It's not something that I would commit. We don't want to add an extra phase that exposes the protected inner symfony email to everyone - it's protected for a reasonπŸ˜ƒ.

    See the link in the IS and perhaps also #8. We could provide an API function that allows registering of a signer function. That function would get called with the symfony email, however it's still protected for all other users.

Production build 0.71.5 2024