0

If a friend wants to send me their S/MIME CA certificate containing his public key, why does he need to add a digital signature?

A digital signature verifies that the content was sent by him and not a man-in-the-middle who has put his own public key in the email. But since we are now talking about a CA certificate (which is signed with the private key of the CA itself saying "yes, this public key belongs to email address yxz") and not just a raw public key, I think a digital signature by my friend is not needed at all, is this right? The articles that I've read were all saying the same thing: "send a public key via email and add a digital signature", but I'm assuming they were assuming a raw public key, not a CA signed one.

Am I correct to assume that a CA certificate can be safely sent via email without any encryption or digital signatures involved?

I guess it's important to distinguish between a public key and a CA certificate which contains a public key. But I would like to have a confirmation by the experts since this is a sensible topic.

10
  • What prevents an attacker from making fake CA certificate? How you distinguish legit and fake CA certificate? Signature is still required to ensure if email was sent by a legit sender by signing email and attaching signing cert to email. Recipient will use signing certificate to ensure if sender is legit.
    – Crypt32
    Aug 19, 2019 at 8:35
  • But the attacker doesn't have the CA's private key to make a fake CA certificate? I thought it works like this: a CA certificate contains name/address + public key + a hash of all these information encrypted with the private key of the CA. So the CA has signed the content of the certificate. Now I use the CA's public key from my root repository to decrypt the hash and compare it to the hash that I get when I hash name/adress + public key. If both hashes match, everything is valid. If a hacker had signed the certificate with is own key, none of my root keys could receive the hash, no?
    – Robert
    Aug 19, 2019 at 11:13
  • "Decrypt the hash"?... If the CA cert your friend is sending is also signed by another CA you both trust, you can send it in email without authentication or encryption no problem. You can then use the root CA cert to verify your friend's CA cert. But earlier you stated that your friend's CA cert is self-signed, so that's not possible. You'll need to use out-of-band authentication.
    – Jenessa
    Aug 19, 2019 at 18:24
  • Are you really talking about sending the CA certificate (containing the CA's public key) or your friend's S/MIME certificate (containing his public key). Your question is contradictory in this matter.
    – mat
    Aug 26, 2019 at 11:19
  • @mat: I don't think a CA certificate "contains the CA's public key"? A CA certificate contains the owners name + public key and a hash of these information. That hash is encrypted with the CA's private key (so, yes, Jenessa, I mean't "decrypt the hash" ... ?) and I can use the CA's public key to decrypt the hash and compare it to the hash that I get, when I hash the owners name + public key. Back to your main question mat: I'm talking about your second case, i.e. a friend sending me his S/MIME certificate - containing his public key, SIGNED by the CA.
    – Robert
    Aug 27, 2019 at 14:31

1 Answer 1

1

He should still sign the e-mail. While you are correct in saying that the certificate itself cannot be forged since it already contains a digital signature from the issuing CA it is still arbitrarily copyable.

A signature on the E-Mail (or any other document) adds the proof, that subject actually does know and control the private key and is able to use it for future secured communication.

4
  • The fact that public key X belongs to person Y was signed by authority Z, how does the certificate being arbitrarily copyable impose a risk? If you copy and somehow alter the owners public key (or name or whatever), the hashes won't match. If you copy and alter the signature, the decryption via the root cert will not provide the correct hash. No?
    – Robert
    Aug 27, 2019 at 15:14
  • I'm not talking about altering the certificate. The subject has had exclusive control of its private key at the time the certificate was issued (assuming the CA followed proper procedures). This might have changed in the meantime. The subject may have lost access to the private key.
    – mat
    Aug 27, 2019 at 15:27
  • By subject you mean the friend? Of course there is a security hole if the friend has lost his private key. But my question was whether it is save to send the certificate via email (without encryption and/or a digital signature) which was issued and signed by a trusted CA.
    – Robert
    Aug 28, 2019 at 7:45
  • With subject in this context I mean the certificate's owner, which is your friend. As said, it is not completely secure since you cannot be sure if the sender of the mail is actually in possession of the private key.
    – mat
    Aug 29, 2019 at 9:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .