General Security Concepts · Topic 7 of 7

PKI and Digital Certificates

Understand public key infrastructure: certificate authorities, trust chains, CSRs, certificate types, CRL, OCSP, stapling and key escrow for Security+.

  • 4 min
  • Includes a diagram
In a nutshell
  • PKI issues and manages certificates. A CA signs them.
  • A certificate links a public key to an identity and is signed by a CA.
  • The private key is never shared. The CSR contains only the public key and identity details.

What it is

A public key infrastructure (PKI) is the set of people, software, policies and hardware that issue, manage and revoke digital certificates.

A digital certificate binds a public key to an identity, such as a web site name. A trusted third party called a certificate authority (CA) signs the certificate, so that others can rely on it without having met the owner.

Serverownersends CSRCertificate authorityCAissuesCertificatesigned public keytrusted byBrowserclient

How it works

Getting a certificate

The owner generates a key pair and builds a certificate signing request (CSR) that contains the public key and identity details. The CA checks the request and signs the certificate with its own private key. The private key stays on the server and is never sent.

Trust chains and root of trust

The root CA signs an intermediate CA, which signs the server certificate. The server owner sends a CSR with the public key and identity details, and the client checks each link of the chain up to a root in its trust store. A browser or operating system holds a store of trusted root CA certificates. A server certificate is normally signed by an intermediate CA, which is signed by the root.

Root CAtrust anchorsignsIntermediate CAissuing CAsignsServer certificateweb site

The root CA is the root of trust. Its private key is guarded closely, often offline, so that a compromise does not spread. A client checks each link of the chain up to a root it already trusts.

Certificate types

TypeUse
Domain validated or extended validationDifferent levels of identity checking by the CA
WildcardCovers all subdomains at one level, such as *.example.com
Subject alternative name (SAN)Lists several names in one certificate
Self signedSigned by its own key, so no outside CA vouches for it
Code signingSigns software so users can check the publisher
EmailSupports signing and encrypting mail

Self signed certificates are fine for lab or internal use, but browsers do not trust them by default. A wildcard certificate is convenient, though a stolen key exposes every subdomain.

Checking whether a certificate is still valid

A client can read the CA's CRL of revoked serial numbers or ask the CA for the status of one certificate with OCSP. With OCSP stapling the web server gets a fresh signed status response and attaches it to the handshake. Certificates can be withdrawn before they expire, for example after a key theft. A certificate revocation list (CRL) is a list published by the CA of revoked certificate serial numbers. The Online Certificate Status Protocol (OCSP) lets a client ask for the status of one certificate in real time.

OCSP stapling lets the server attach a fresh, signed status response to the handshake. This saves the client from contacting the CA and also improves privacy.

Key escrow and recovery

Key escrow keeps a copy of a private key with a trusted party so that encrypted data can be recovered. It is useful when an employee leaves or loses a key, but the escrow store must be protected like any other secret.

What to remember for the exam

  • PKI issues and manages certificates. A CA signs them.
  • A certificate links a public key to an identity and is signed by a CA.
  • The private key is never shared. The CSR contains only the public key and identity details.
  • The root CA is the root of trust, and intermediate CAs protect it by doing the daily signing.
  • A CRL is a published list of revoked certificates. OCSP checks one certificate on demand.
  • OCSP stapling lets the server provide the status response itself.
  • A wildcard certificate covers subdomains. A SAN certificate lists specific names.
  • A self signed certificate is not trusted by clients unless it is added manually.
Exam tip

When a question describes a client checking whether one certificate has been revoked right now, the answer is OCSP, not a CRL.

Common mistakes

Sending the private key to the CA. The CA only needs the public key in the CSR. The private key must stay with the owner.

Assuming expiry and revocation are the same. Expiry is a planned end date. Revocation ends trust early and is announced through a CRL or OCSP.

Trusting a certificate because it exists. A client must also check the name, the validity dates, the chain and the revocation status.

Using one wildcard certificate everywhere. A single key leak then affects every host that shares it.

Confusing a CA with a registration authority. The CA signs the certificate. A registration authority only helps verify identity before the CA issues it.

Watch out

A self signed certificate on a public site makes users click through browser warnings, which trains them to ignore real warnings.

Check yourself

  • What does a CSR contain?

    The public key and the identity details of the requester. The private key is not included.

  • How is OCSP different from a CRL?

    OCSP queries the status of a single certificate on demand, while a CRL is a published list of all revoked certificates.

  • Why are intermediate CAs used?

    They sign day to day certificates, so the root CA key can stay protected and often offline.

Topic 7 of 7 in General Security Concepts

Test yourself on General Security Concepts

The full CompTIA Security+ SY0-701 question bank has 848 questions, with timed practice exams and an explanation for every answer.

This study guide is independent and is not affiliated with, endorsed by, or sponsored by CompTIA. Vendor names, certification names and exam codes are trademarks of their respective owners and are used for identification only.