← Back to all services
Mail Servers

OpenDKIM Port & Email Authentication Setup

opendkim systemctl: opendkim

DKIM signing and verification daemon for email authentication.

🔌 Default Port

8891
tcp
Milter socket (or unix socket)

📦 Installation Command

apt install opendkim opendkim-tools

⚙️ Configuration Files

  • /etc/opendkim.conf
  • /etc/opendkim/KeyTable
  • /etc/opendkim/SigningTable
  • /etc/opendkim/TrustedHosts

📂 Default Directories

  • config: /etc/opendkim.conf
  • keys: /etc/opendkim/keys
  • logs: /var/log/mail.log
  • socket: /var/spool/postfix/opendkim/opendkim.sock

🔐 Default Credentials

Username:N/A
Password:N/A
💡 No user auth - works as milter for Postfix

📌 Dependencies

postfix or other MTA

⚠️ Conflicts

N/A Port: N/A

✅ Works With

postfixsendmail

🛡️ Security Notes

Secure key permissions (0600), rotate keys periodically, monitor signing failures

❓ Frequently Asked Questions

What port does OpenDKIM use?
OpenDKIM uses port 8891 by default for the milter interface.
What is DKIM?
DKIM (DomainKeys Identified Mail) signs emails cryptographically to verify sender authenticity.
Where is OpenDKIM config?
Config at /etc/opendkim.conf with keys in /etc/opendkim/keys/.