Menu

#5621 DKIM signing failure

2.021
closed-fixed
nobody
None
5
2023-06-12
2023-06-02
No

I'm spinning up a new Ubuntu 22.04/Virtualmin 2.021 installation and I've hit problems with DKIM signing not working on outgoing mail (via Postfix), which has been a common problem over the years (not always Webmin's fault). I'm pleased to report that most of the earlier problems are now resolved but there's one remaining one I thought I should report, because it took me some time to find and the answer didn't show up in Google.

In short, the linux user "postfix" needs to be manually added to the "opendkim" group (Webmin > System > Users and Groups > Edit user). That's it.

Discussion

  • Jamie Cameron

    Jamie Cameron - 2023-06-03

    Hmm, odd that this group addition didn't happen as part of the DKIM package install. Did you just use the package that comes with Ubuntu 22.04 (or was installed by Virtualmin) ?

     
  • Phil McKerracher

    Yes, it was the standard Ubuntu package. I'm not sure exactly when it was installed - it's possible I installed it from the command line (using apt) before I enabled DKIM in Virtualmin, which would have triggered the same thing, I think.

     
  • Jamie Cameron

    Jamie Cameron - 2023-06-08

    Ok .. and what error did you get before the postfix user was added?

     
  • Ilia

    Ilia - 2023-06-09

    No error anywhere. Just no DKIM signature in outgoing mail.

    You better ask this question at forum.virtualmin.com website.

    Also, for DKIM to work properly, Virtualmin needs to have control over DNS or you should manually add DKIM related records to domain's DNS zone.

     
  • Phil McKerracher

    It's not a question, it's a bug report. It's not related to DNS at all as far as I can tell.

     
  • Jamie Cameron

    Jamie Cameron - 2023-06-10

    Did you see any error messages in /var/log/maillog or mail.log ?

     
  • Phil McKerracher

    No, at least nothing relevant as far as I could tell. The messages were sent successfully, just without their DKIM signature. It should be pretty easy to reproduce.

     
  • Jamie Cameron

    Jamie Cameron - 2023-06-12

    I had a look into this some more, and found that adding the postfix user to the opendkim group isn't necessary if a TCP socket is being used to communicate between Postfix and the DKIM milter. But it is needed if a socket file is used ... so I'll make sure the group is setup correctly in all cases in the next release.

     
  • Jamie Cameron

    Jamie Cameron - 2023-06-12
    • status: open --> closed-fixed
     

Log in to post a comment.

MongoDB Logo MongoDB