Picture an invented fintech called Nila Pay. On a Saturday at 12:05 a.m., merchants begin reporting that the checkout page shows a full-screen warning. Nothing was deployed. No server crashed. A certificate on the load balancer reached the end of its validity period, and nobody had put the renewal in a calendar. We will use Nila Pay’s bad night to walk through what a certificate is, who stands behind it, and where it breaks.
What the certificate actually says
A certificate is a small signed document that binds a public key to a name. The name for Nila Pay would be something like pay.nilapay.example. It contains the public key, the names it covers (the subject alternative name field is what modern browsers check), the dates it is valid between, and the signature of whoever issued it.
Public-key cryptography solves how two strangers can agree on a secret across an open network, but it leaves a hole: how do you know this public key really belongs to Nila Pay, and not to someone sitting in a coffee shop network pretending to be it? The answer is that someone you already trust signs a statement saying so. That someone is a certificate authority, or CA.
The chain, and where trust starts
Your browser or operating system ships with a list of root certificates it trusts, called a trust store. Roots are rarely used to sign websites directly, because their private keys are kept extremely well protected, often offline. Instead a root signs an intermediate CA, and the intermediate signs the leaf certificate, the one on Nila Pay’s server.
When a browser connects, the server sends the leaf and the intermediate. The browser checks that the leaf’s signature verifies with the intermediate’s key, that the intermediate’s signature verifies with a root in its trust store, and then runs a few more tests. Is the current time inside the validity window? Does the requested hostname match one of the names listed? Has anything in the chain been revoked? Fail any one, and the padlock turns into a warning.
A frequent real-world fault is a server that sends only the leaf and forgets the intermediate. Some clients cope by fetching it; others do not, so the site works on one laptop and fails on one phone. Teams lose hours to this because the symptom looks random.
Back to midnight at Nila Pay
The warning merchants saw was not an attack. The leaf certificate’s “not after” date had passed, so the validity test failed, and the browser refused, correctly. Think about why this is deliberate. Expiry limits the damage of a stolen private key: a key that leaked years ago cannot be abused forever. It also forces the owner to prove control of the domain again, regularly.
The lifetime of publicly trusted web certificates has been shrinking. It was once measured in years, then capped at about 13 months, and the industry body that sets the rules for browsers and CAs has agreed to shorten it in stages further. Check the current maximum when you plan; the direction is clear. Shorter lives make manual renewal untenable, and that is the lesson for Nila Pay: automate issuance and renewal (protocols such as ACME exist for exactly this), and monitor the expiry dates of everything, not just the public website. Internal services, API gateways, VPN appliances and mail servers all hold certificates that fail just as loudly.
What if a key is stolen before expiry?
Suppose someone copied Nila Pay’s private key in March. The certificate is valid until December. Revocation is the escape hatch. A CA can publish a certificate revocation list, or answer live queries through OCSP, the Online Certificate Status Protocol, to say a given certificate is no longer to be trusted.
In practice revocation checking is patchy. Clients may skip it, or fail open if the responder is unreachable, because blocking every site during an OCSP outage would be worse. This is one reason shorter lifetimes are attractive: they make revocation less critical. Whenever a key may have leaked, though, revoke and reissue anyway, with a new key pair. Reusing the old key in the new certificate defeats the point.
Other places certificates appear
- Private PKI. Companies run their own CA for internal systems and install its root on employee devices. Cheap and flexible, but you own the burden of protecting that CA and handling revocation.
- Mutual TLS. The client also presents a certificate, so both sides authenticate. Common between services.
- Document signing in India. Digital signature certificates used for GST filing or MCA forms are issued by CAs licensed under the Controller of Certifying Authorities, under the IT Act. Same cryptographic idea, different trust framework.
- Certificate Transparency. Public CAs log the certificates they issue in open, append-only logs. Domain owners can watch those logs and notice a certificate issued for their name that they did not request.
What an attacker would need
To impersonate a site convincingly, an attacker needs one of a few things: the site’s private key, a CA that wrongly issues a certificate (rare, and heavily scrutinised), or a device they have already persuaded the user to configure to trust a rogue root. That last one is why corporate inspection proxies work, and why malware that installs a root certificate is so serious. Trust is a list on a machine, and whoever edits the list edits who can pretend to be anyone.
Nila Pay’s fix took twenty minutes once someone found the expired certificate. The real fix took longer: an inventory of every certificate, owners named against each, automated renewal, and alerts at 30, 14 and 7 days. It is dull work, and it prevents the most embarrassing kind of outage there is.
Figures and names in the examples are illustrative.
Leave a Reply