• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question DKIM: where is the public key stored?

onlinesolutions

Basic Pleskian
When enabling DKIM, there is a private key stored on your server and a public key that is stored in the DNS. I don´t have DNS installed in Plesk, so where would I find the information that needs to be set up as a DNS record?
 
As a text record you copy a part of the contents from the file /etc/opendkim/keys/yourdomain.com/mail.txt (or default.txt), it data should start from v=DKIM1; k=rsa; to the end, without the quotes as you can see it’s in quotes.

It'll look like this example:
Code:
v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDPzE0GmvFwAQsgcFzopy4zMNWUbL6JM5XIyjBy3bUnANI5axeb/Lw/GBjUoSFLEiO80Tt8m3A5YrBKcodRQQURYiW6/YtElhLupHyfcxQhfNLU4z9JUOJKPjcpMZCj0Xv873QgVOl+7U605JdBHSPOx4ybBZwDq68cw9YFYRPmEwIDAQAB

You'll copy this code as a txt record to your DNS host.
 
Last edited:
As a text record you copy a part of the contents from the file /etc/opendkim/keys/yourdomain.com/mail.txt (or default.txt), it data should start from v=DKIM1; k=rsa; to the end, without the quotes as you can see it’s in quotes.

It'll look like this example:
Code:
v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDPzE0GmvFwAQsgcFzopy4zMNWUbL6JM5XIyjBy3bUnANI5axeb/Lw/GBjUoSFLEiO80Tt8m3A5YrBKcodRQQURYiW6/YtElhLupHyfcxQhfNLU4z9JUOJKPjcpMZCj0Xv873QgVOl+7U605JdBHSPOx4ybBZwDq68cw9YFYRPmEwIDAQAB

You'll copy this code as a txt record to your DNS host.
Thank you for your response. It is not stored there, but I figured out I can generate the key byopenssl rsa -in default -pubout -out public as the private keys are in fact stored in etc/domainkeys/DOMAIN.com
 
Back
Top