1

Is CA the only way to securely share public key - are there other mechanisms that are viable in practice?

I guess if you had a trusted software deployment system that securely transmitted contents from itself to the host, you can use that to deploy the public key there as well?

I believe you also want to rotate the private keys frequently and for that a CA might be a better way?

3
  • A public key is "public", so technically I don't see the point of sharing it via a secure channel. In a public-key infrastructure, public keys are accessible to anyone so that an entity can verify a digital signature produced by the originator's corresponding private key (thanks to the beauty of asymmetric encryption). Are you sure you are referring to the public key in your question?
    – zyk
    Commented May 28, 2020 at 15:56
  • 2
    @zyk It's not about the keys confidentiality, but about its integrity. Without a CA or some other mechanism to establish trust, you wouldn't know if the public key example.com gives you actually belongs to example.com. If it belongs to evil.com, they can now decrypt your traffic.
    – tim
    Commented May 28, 2020 at 16:42
  • @tim Yes, I agree with you - I momentarily forgot about the aspects of integrity and authenticity which are within the definition of "secure". As some other answers suggest, these can be also be achieved through a web of trust, out-of-band checks, etc.
    – zyk
    Commented May 28, 2020 at 17:04

3 Answers 3

2

A CA is not a way to share a public key in the first place. The idea behind signing a certificate (which contains the public key) by a CA is to propagate an existing trust into a CA to the certificate. How the signed certificate is then shared does not matter because nothing is secret in it and the recipient can detect any modifications since these would invalidate the signature from the trusted CA.

In practice there are many ways to securely share a public key. The main requirement is that the transport or container can be trusted trusted and that it protects against manipulation of the contents. This can be achieved when communicating with TLS with a trusted server, by sending the key inside an S/MIME mail signed by a trusted sender, by signing a certificate by a trusted CA etc.

4
  • What is the difference between signing a message and signing a certificate? I know how to sign a message. I don't know how to sign a certificate.
    – user855
    Commented May 28, 2020 at 20:33
  • @user855: A "message" is data. It can be a mail, it can be a certificate, it can be a program, it can be some XML fragment etc. The basic idea is the same for S/MIME signing, certificate signing, code signing etc but the exact way how the data and the signature are put together into a single container varies. Commented May 28, 2020 at 21:41
  • My understanding is that the private key needs to be used for signing. So to sign a certificate a CA needs to create a new certificate for an entity and then sign that certificate using its private key. Correct?
    – user855
    Commented May 29, 2020 at 4:03
  • @user855: basically correct. The information in the certificate (which is just structured data) comes at least in parts from the party requesting the certificate. Specifically the public key in the certificate is provided by the requesting party which also has the matching private key (and keeps it secrets). Commented May 29, 2020 at 5:37
2

Some other mechanisms:

  • Web of trust - e.g. PGP. This is a peer-to-peer system, where instead of CAs that everyone trusts, each user trusts some keys directly (e.g. ones confirmed at a key signing party) and can follow a chain.
  • Out of band verification - e.g. SSH. When an unknown key is encountered, it's displayed for the user to verify out-of-band (although no-one bothers in practice) and if valid it is stored. Some people also share their known_hosts file over a secure channel.
  • Secure channel - e.g. Group Policy in an AD environment. The AD administrators can leverage existing secure connections between DCs and other systems, and use this to deploy new certificates.

In most environments, private keys are not rotated frequently; validity would typically be measured in years.

0

I am not certain you fully understand what a CA is.

A Certificate Authority (CA) is an entity who tops a Public Key Infrastructure (PKI) hierarchy. Its public certificate is the part that needs to be implicitly trusted by all parties in order to enable validation of signatures in a hierarchy.

Public keys are by definition public. The concern is having those intercepted and replaced in transit - in an elaborated scenario, this could completely defeat a PKI should the attacker be able to permanently monitor and intercept all communications.

You must log in to answer this question.

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