skip to content

An IT team rolls out S/MIME certificates to 400 staff: one batch signs but nobody can encrypt to it, another's signatures are rejected by recipients; what in each certificate profile explains it?

level: seniorimportance: should knowfreq 20%

answer

  1. dump both batches and compare
  2. which operations does the key allow
  3. a key type that only signs
  4. the mail key purpose is missing

basics

~20 s

The first batch is signing-only: keyUsage carries digitalSignature without keyEncipherment or keyAgreement, for example because the key is EdDSA. The second lacks id-kp-emailProtection in its extended key usage, or lacks both signature bits, so RFC 8550 receivers must refuse it.

solid answer

~40 s

Dump one certificate from each batch and read `subjectPublicKeyInfo`, `keyUsage` and `extKeyUsage` together. The batch nobody can encrypt to has a signing-only profile: `digitalSignature` (perhaps `nonRepudiation`) with no `keyEncipherment` or `keyAgreement`; with an Ed25519 key the Baseline Requirements allow nothing else, so the fix is a second, key-management certificate or reissuing with an RSA or P-256 key as dual use. The batch whose signatures are rejected usually came from the wrong template: an `extKeyUsage` holding only `id-kp-clientAuth`, which RFC 8550 receivers must refuse because a present EKU must contain `id-kp-emailProtection` or `anyExtendedKeyUsage`. A key-management-only certificate used for signing fails the same way under RFC 8550's keyUsage rule. Only after the profile checks out are address mismatches or an untrusted issuer worth chasing.

code

plaintext · 10 lines
plaintext
# batch A
subjectPublicKeyInfo: id-Ed25519
keyUsage (critical): digitalSignature
extKeyUsage: id-kp-emailProtection
subjectAltName: [email protected]
# batch B
subjectPublicKeyInfo: id-ecPublicKey, P-256
keyUsage (critical): digitalSignature, keyAgreement
extKeyUsage: id-kp-clientAuth
subjectAltName: [email protected]

go deeper

for a junior

Recall that a certificate's keyUsage and extended key usage decide what mail clients may do with it, and that signing and encryption need different bits.

for a middle

Explain why a signing-only profile blocks encryption silently, and why an EKU listing only clientAuth fails RFC 8550's check.

for a senior

Diagnose from the extracts in order: key algorithm, keyUsage, extKeyUsage, then addresses, and only then trust anchors or revocation; propose a fix with its cost.

for a principal

Turn the incident into an ordering standard: a written profile per purpose and an end-to-end test certificate before any batch, owned by the team that buys certificates.

## The situation An IT team orders mailbox certificates for 400 employees from a commercial certificate issuer. After rollout two complaints arrive. Staff in the first batch can sign, and their signatures verify, but correspondents report that their mail clients offer no way to encrypt to them. Staff in the second batch sign normally, yet recipients' clients mark every signature as invalid or untrusted. Neither problem produces a clear error at the sender: a wrong certificate profile **fails silently**, at someone else's desk. ## Step 1: read the three fields together For one certificate from each batch, read: - `subjectPublicKeyInfo`: the key algorithm, which decides which key usage bits are even possible. - `keyUsage`: the operations the key may perform. - `extKeyUsage`: the application purposes; RFC 8550 makes the usable set the **intersection** of the two extensions. Also note `subjectAltName` and the `certificatePolicies` identifier, but only after the first three. ```plaintext # batch A subjectPublicKeyInfo: id-Ed25519 keyUsage (critical): digitalSignature extKeyUsage: id-kp-emailProtection # batch B subjectPublicKeyInfo: id-ecPublicKey, P-256 keyUsage (critical): digitalSignature, keyAgreement extKeyUsage: id-kp-clientAuth ``` ## Batch A: signing-only Batch A's `keyUsage` holds `digitalSignature` and nothing for key management. A correspondent's client looking for a key to protect the content key finds neither `keyEncipherment` (key transport, for RSA) nor `keyAgreement` (ECDH, for elliptic-curve keys), so it will not use the certificate for encryption. Here the cause is structural: the key is **Ed25519**, an EdDSA signing key. The CA/Browser Forum S/MIME Baseline Requirements (1.0.16) allow EdDSA and ML-DSA keys only the signature bits, so no reissue of the same key can fix it. Remedies, each with a cost: 1. **Add a key-management certificate** for each person (RSA with `keyEncipherment`, or a P-256 key with `keyAgreement`). This is the separate-keys model and doubles the certificates per mailbox. 2. **Reissue as dual use** with an RSA or P-256 key, setting `digitalSignature` with `keyEncipherment` or `keyAgreement`. One certificate, but signing and decryption now share a key. 3. Do nothing, if the policy really was signing only; then tell users that nobody can send them encrypted mail. ## Batch B: rejected signatures Batch B's signatures fail at recipients for a profile reason. Its `extKeyUsage` lists only `id-kp-clientAuth`, the purpose of a certificate meant for authenticating to services. RFC 8550 says that when the extension is present, an interpersonal-mail receiving agent **MUST check** that it contains `id-kp-emailProtection` or `anyExtendedKeyUsage`; this one contains neither, so the certificate is not a mail certificate whatever its key usage says. The likely cause is an order placed against the wrong product or template. Publicly trusted S/MIME certificates always carry `id-kp-emailProtection`, because the Baseline Requirements define an S/MIME certificate by that key purpose plus a mailbox in `subjectAltName`. Other profile faults that produce the same symptom: - A **key-management-only** certificate (`keyEncipherment` or `keyAgreement`, no signature bit) installed as the signing certificate: RFC 8550 says receivers **MUST NOT accept** a signature verified with a certificate lacking both `digitalSignature` and `nonRepudiation`. - A user signing from an alias that is not among the certificate's `subjectAltName` entries, which shows as an address mismatch rather than a broken signature. | Symptom | Field to read | Profile fault | |---|---|---| | Nobody can encrypt to the holder | `keyUsage`, key algorithm | No `keyEncipherment` / `keyAgreement`; EdDSA or ML-DSA key | | Signatures rejected outright | `extKeyUsage` | No `id-kp-emailProtection` (for example `id-kp-clientAuth` only) | | Signatures rejected outright | `keyUsage` | No `digitalSignature` or `nonRepudiation` | | Address warning on a valid signature | `subjectAltName` | Sending address not listed | ## When the profile is clean If both batches pass these checks, the remaining causes sit outside the certificate profile: recipients whose clients do not trust the issuing hierarchy, which is a question of trust anchors and path validation, or a revoked certificate. Those are covered with certificate discovery and trust and with revocation checking. ## Preventing a repeat - Specify the profile in the order: key algorithm, `keyUsage` per purpose, `extKeyUsage` containing `id-kp-emailProtection`. - Test one certificate end to end before the batch: sign to an outside mailbox, and have an outside correspondent encrypt to it. - Record which generation and validation type the policy identifier shows, so the next renewal does not drift.

  • Batch A's Ed25519 certificates cannot be reissued as dual use. Why not, and what is the least disruptive fix?
    EdDSA is a signature algorithm, so the Baseline Requirements allow its certificates only digitalSignature and optionally nonRepudiation. The least disruptive fix keeps the signing certificates and adds a key-management certificate per person, RSA with keyEncipherment or P-256 with keyAgreement, which correspondents can encrypt to.
  • Why does batch B's keyUsage, which includes digitalSignature, not rescue its signatures?
    RFC 8550 makes the usable purposes the intersection of keyUsage and extKeyUsage, and requires a present EKU to contain id-kp-emailProtection or anyExtendedKeyUsage. With only id-kp-clientAuth the certificate is outside the mail purpose entirely, so a digitalSignature bit does not make it acceptable for S/MIME.
  • How would you catch both faults before a batch of 400 ships?
    Write the profile into the order, then issue one test certificate and exercise it end to end: sign a message to an outside mailbox and ask an outside correspondent to encrypt to the holder. Reading keyUsage, extKeyUsage and the key algorithm of that one certificate would have shown both faults.

  • Signatures verify, so the certificate must be fine for encryption too.
  • Rejected signatures always mean the recipient lacks the issuer's root.
  • An Ed25519 certificate can be reissued with keyAgreement added.
  • digitalSignature in keyUsage overrides an extended key usage without emailProtection.
  • Any certificate from a commercial issuer works for S/MIME.