Distinguish DNS and IP entries in a certificate SAN
Admin ·
One certificate can name several identities. The SAN extension records each identity with a type that affects its interpretation.
Compare three identity entries
A certificate might list DNS api.example.test, DNS *.example.test and IP 2001:db8::1. Read the value together with its type. A wildcard is stored as one entry and a numeric IP is encoded differently from a DNS label.
IETF RFC 5280 — Internet X.509 Public Key Infrastructure Certificate Profile
Look for absent or unsupported entries
Check the subject and certificate number first. A certificate with a common name can have no SAN extension. If the extension contains a name form the reader cannot decode, the report marks it unsupported.
IETF RFC 5280 — Internet X.509 Public Key Infrastructure Certificate Profile
Read a wildcard and a separately listed name
Suppose a saved certificate lists *.example.org and api.example.net. Preserve both entries exactly when recording observed identities. A wildcard is one encoded name, not a list of every host that currently exists.
A hostname and a literal IP address use different SAN entry types. Check the type as well as the displayed text. Extracting the list does not determine whether a particular client trusts the certificate.
Common questions
Can a bundle contain different SAN lists?
Each certificate is decoded separately. The tool preserves the order in which you supplied the certificates.
Does a DNS name prove an address is online?
The extension records a certificate identity. Current DNS or service availability requires a separate observation.
Sources
Put it into practice.
- Certificate SAN Extractor
- X.509 Certificate Inspector
- SSL Certificate Expiry Checker
- Certificate Fingerprint Generator