DKIM Signature Missing from Outgoing Emails (ISPConfig 3.2.12p1, Ubuntu 20.04)

Discussion in 'General' started by clamp2x, Feb 8, 2025.

Tags:
  1. clamp2x

    clamp2x New Member

    Hello,

    I am running ISPConfig 3.2.12p1 on Ubuntu 20.04, and have enabled DKIM signing for my domain (example.com).
    However, despite correct configuration, my outgoing emails do not include a DKIM-Signature header.

    I have not manually modified any permissions or server configurations and have strictly followed ISPConfig's default settings during installation.

    Additionally, Reverse DNS (PTR) is correctly set up and points to my mail server.

    My Setup & What I've Checked

    1. ISPConfig Configuration
      • DKIM signing is enabled for my domain (example.com).
      • SPF (v=spf1 mx ~all) and DMARC (v=DMARC1; p=none) records are correctly set.
      • The DKIM public key is correctly published in the DNS TXT record.
      • Reverse DNS (PTR) correctly points to my mail server.
    2. DKIM Key Files Exist & Are Managed by ISPConfig
      • The private & public DKIM keys were automatically generated by ISPConfig and exist in /var/lib/amavis/dkim/.
      • Checked with:
        Code:
        ls -l /var/lib/amavis/dkim/
      • I have not manually modified permissions or ownership of these files.
    3. Amavis & Postfix Are Configured Properly
      • amavis is running and correctly processing emails:
        Code:
        systemctl status amavis
      • Mail log confirms Amavis is processing outgoing emails:
        Code:
        Passed CLEAN {RelayedOutbound}, ORIGINATING LOCAL [127.0.0.1] <[email protected]> -> <[email protected]>
      • content_filter is correctly set in Postfix:
        Code:
        postconf -n | grep content_filter
        Output:
        Code:
        content_filter = smtp-amavis:[127.0.0.1]:10024
    4. Checking Amavis for DKIM Activity
      • No DKIM-related logs found when checking mail logs:
        Code:
        sudo grep "DKIM" /var/log/mail.log
        (No output)

      • Amavis debug mode does not show any DKIM signing activity:
        Code:
        sudo amavisd-new debug
        No messages like DKIM key loaded or Signing skipped appear.
    5. Ensuring Postfix Is Not Removing DKIM Headers
      • No custom header_checks that might remove DKIM headers:
        Code:
        cat /etc/postfix/header_checks
        (File is empty)

      • No suspicious cleanup settings:
        Code:
        postconf -n | grep cleanup
        (No settings that would interfere with DKIM headers)
    6. Tried ISPConfig & Service Restarts
      • Forced ISPConfig update to reapply configurations:
        Code:
        sudo ispconfig_update.sh --force
      • Restarted all related services
    The Problem

    Despite all configurations appearing correct:

    • DKIM signing is enabled in ISPConfig
    • DNS TXT record for DKIM is correct
    • Reverse DNS (PTR) correctly points to my mail server
    • Amavis is processing outgoing emails (as ORIGINATING)
    • Postfix correctly routes mail through Amavis
    • DKIM-Signature header is missing from outgoing emails
    • No DKIM-related logs in Amavis debug mode
    I have followed ISPConfig’s default settings and have not modified any permissions or system configurations manually.

    My Question

    • Why is Amavis not applying DKIM signatures to my outgoing emails?
    • What further troubleshooting steps should I take?
    I appreciate any help!
    Thanks in advance.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    How did you send the test emails? Please ensure that you are authenticated when sending with username and password (smtp auth) e.g. by using an email client like Thunderbird to connect to your system.
     
  3. clamp2x

    clamp2x New Member

    I logged into my email using Roundcube within ISPConfig and sent an email to Gmail.com.
    I also tested by sending an email to https://dkimvalidator.com/ to check the DKIM signature.
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    ReoundCube does not necessarily use SMTP-auth for sending as it sends on localhost. Please verify by using an email client from your desktop PC or mobile phone.
     
  5. remkoh

    remkoh Active Member HowtoForge Supporter

    Does smtp-auth realy matter? I don't think so.
    As long as roundcube uses the same MTA as the client would do then dkim signing should be done by the MTA regardless of where the mail was send from (roundcube or client).
     
  6. clamp2x

    clamp2x New Member

    Previously, when sending emails via Roundcube, DKIM authentication was working correctly. However, now emails are being sent without the DKIM signature.

    Additionally, I registered an email account created on the server in the iPhone Mail app and sent an email through it, but DKIM is still not being added.
     

Share This Page