LetzRelay blog

log

November 18, 2022


Email security: What is the difference between DKIM signature and PKCS#7 signature?


blog post 2022-11-18

Introduction

When it comes to email security, one of the key tools that can be used is email signatures. These are added in the technical headers of an email message, and they provide a way to verify the authenticity of the message and ensure that it has not been tampered with during transit.

There are two main types of email signatures that are commonly used: DKIM (DomainKeys Identified Mail) and PKCS#7 (Public Key Cryptography Standard #7). In this article, we will delve into the differences between these two email signatures, and explore the benefits and drawbacks of each.

DKIM and PKCS#7, somehow the same goal but different approaches

DKIM email signature

DKIM is an email authentication method that allows the person receiving an email to check that it was actually sent by the domain it claims to have been sent from, and that it has not been modified in transit. It works by adding a digital signature to the headers of the email message, which can be verified by the recipient's email server. This signature is created using a private key that is held by the sender, and it is verified using a public key that is published in the sender's DNS records.

One of the main benefits of DKIM is that it allows for a higher level of security than traditional methods of email authentication, such as SPF (Sender Policy Framework) or S/MIME (Secure/Multipurpose Internet Mail Extensions). It also allows for a more efficient way of verifying the authenticity of an email, as it requires fewer steps to complete the process.

However, there are also some drawbacks to using DKIM. One of the main issues is that it requires the sender to have access to a domain private key, which can be difficult to manage and maintain. It also requires the sender to have access to their DNS records, which can be a problem if they do not have control over their domain. Another relates to the fact that DKIM does not authenticate the sender theirself, but rather the domain that the email claims to have been sent from.

PKCS#7 email signature

PKCS#7 is a standard for public key cryptography that is used to create and verify digital signatures. It is often used in conjunction with other security protocols, such as SSL (Secure Sockets Layer) or TLS (Transport Layer Security), to provide a higher level of security for online transactions.

Unlike DKIM, PKCS#7 uses a certificate issued by a trusted authority to create a digital signature. This signature is then verified using the certificate's public key.

One of the main benefits of PKCS#7 is that it does not require the sender to have control over their domain or access to their DNS records. This makes it a more flexible option for email authentication, as it can be used by anyone with a valid certificate. It is also easier to implement and maintain than DKIM, as it does not require the sender to manage a private key. PKCS#7, to the opposite of DKIM, authenticates the sender theirself.

However, there are also some drawbacks to using PKCS#7. One of the main issues is that it requires the use of a trusted authority to issue certificates, which can be a costly and time-consuming process.

Conclusion

Both DKIM and PKCS#7 are effective methods of email authentication that can help to ensure the security and integrity of email messages. DKIM requires the sender to have access to a private key and DNS records. PKCS7 is easier to implement and maintain, but it requires the use of a trusted authority to issue certificates. Ultimately, the best option for email authentication will depend on the specific needs and resources of the sender. If affordable, both should be implemented organization-wise.

Learn more on how LetzRelay-MX can help your organization be secured with Internet inbound emails.


Internal publication.

© LetzRelay by AlSego.