A wildcard certificate puts one private key in charge of every hostname one level under your domain, so a single compromised server can become a problem for the whole domain. If you run *.example.com across web servers, load balancers, staging boxes and vendor-hosted pages, this article explains how wildcard certificates widen the blast radius of a breach, where the risk actually sits, and how to keep the convenience without exposing the whole domain.
The key gets copied everywhere, and every copy is trusted for every name
If the key for a certificate issued to shop.example.com leaks, an attacker can impersonate shop.example.com. If the key for *.example.com leaks, the attacker can impersonate login.example.com, api.example.com, vpn.example.com and any subdomain you haven’t created yet. Those names don’t depend on the server the key was stolen from. They depend on the domain.
The cryptography is no weaker. A wildcard uses the same RSA or ECDSA keys as any other certificate. The problem is how teams handle it. Because one certificate works everywhere, it gets copied everywhere. The key is then only as safe as the most neglected server that holds a copy.
How one wildcard key ends up on 14 hosts
The pattern is familiar. Someone issues *.example.com for the main Nginx cluster. A month later staging needs HTTPS, so the PEM files get copied over. Then the Grafana instance gets a copy, followed by the old Jenkins box, the webmail front end, the F5 in the data center, a CDN custom certificate slot and a contractor’s landing page host.
Count the exposure. Suppose the key sits on 14 hosts and each host has about 5 people with root or sudo. That’s up to 70 accounts that can read the key file. The number grows once you add backups, configuration management repositories, CI secrets and the laptop that generated the CSR.
With a certificate per service, a breach of the staging server exposes staging and nothing else. With a shared wildcard, staging is usually the least patched machine you have, and it becomes the easiest way in to your production identity.
What a stolen wildcard key actually enables
A common myth says a leaked key lets anyone read your traffic right away. It doesn’t. TLS 1.3 and TLS 1.2 ECDHE suites provide forward secrecy, so recorded past sessions stay protected. To use the key, the attacker needs a position in the traffic path. A hijacked DNS record works, and so do a rogue Wi-Fi network, a malicious internal proxy or a BGP hijack.
That bar is lower than it sounds. From any of those positions the attacker can present a fully valid certificate for any subdomain. Browsers show no warning, and nothing new appears in Certificate Transparency logs, because the certificate already exists. CT monitoring catches newly issued rogue certificates. It cannot see misuse of a legitimate one.
Wildcards also enable cross-protocol attacks. The ALPACA research, published in 2021, showed that an attacker could redirect a browser’s HTTPS traffic to another service on a different subdomain, such as an FTP or mail server. The redirect works when that service presents a certificate valid for the name, and the attacker then exploits the different ways the two services parse requests. A wildcard makes this trivial, because files.example.com and app.example.com share one valid certificate. The NSA published guidance in October 2021 recommending against broad wildcard use for this reason.
Revocation turns a breach into an outage
Under the CA/Browser Forum Baseline Requirements, a CA must revoke a certificate within 24 hours of a reported key compromise. For a single-host certificate, that means one quick swap. For a wildcard on 14 systems, you must reissue and redeploy everywhere inside that window. That includes appliances with manual upload screens and vendor platforms where you file a ticket and wait.
Revocation also gives less protection than people assume. Chrome doesn’t run live OCSP checks for most certificates, so a revoked wildcard can keep working in browser-facing attacks until it expires. The steps that follow a key leak are covered in more depth in why leaked private keys demand immediate certificate revocation.
Expiry is the more reliable limit. Since March 2026 the maximum validity for public certificates is 200 days. It drops to 100 days in March 2027 and to 47 days in March 2029. Shorter validity caps how long a stolen key stays useful, but only if each renewal generates a new key.
Habits that quietly make the blast radius bigger
Reusing the key at renewal. Manual renewals often resubmit last year’s CSR, and certbot’s –reuse-key flag does the same thing on purpose. The result is that a key leaked two years ago still matches the certificate you deployed last week. Generate a fresh key every time.
Storing DNS API tokens next to the certificate. ACME CAs such as Let’s Encrypt issue wildcards only through the DNS-01 challenge. Teams therefore often place a Cloudflare or Route 53 API token on every server that runs certbot, frequently with edit rights for the whole zone. An attacker who compromises one of those servers gets the key and also the power to redirect DNS and issue new certificates. Scope the token as tightly as your provider allows, or point _acme-challenge with a CNAME to a separate zone used only for validation.
Giving the wildcard to vendors. When a marketing agency needs HTTPS on promo.example.com, sending them your wildcard puts your production identity on infrastructure you cannot audit. Give them a certificate of their own, or let them issue one after you point the name to them with a CNAME.
Containing wildcard certificate risk without dropping wildcards
Wildcards have legitimate uses. Examples include multi-tenant SaaS with customer.app.example.com, preview environments created for each pull request, and platforms where issuing per host would hit CA rate limits. The goal is containment, not a ban.
1. Find every copy. On each host, run openssl s_client -connect host:443 -servername host Narrow the scope. A wildcard covers exactly one label, so *.preview.example.com cannot impersonate login.example.com. Put tenant and preview names under their own subdomain.
3. Terminate TLS in one tier. Keep the wildcard on the load balancer or reverse proxy and give backends individual internal certificates. The key then lives on 2 hosts instead of 14. Ideally it sits in a KMS or HSM, as covered in private key protection best practices.
4. Use a separate key for each deployment. You can issue several certificates for the same wildcard name, each with its own key. The CDN copy and the on-premises copy can then be revoked independently.
5. Restrict issuance with CAA. The issuewild tag controls wildcard issuance separately from regular certificates. Setting it to “;” blocks wildcards for the zone. Naming a single CA in it limits who can issue them.
6. Watch where the certificate is served. Ongoing checks across subdomains, as described in how to monitor wildcard SSL certificates across subdomains, catch new copies before they become forgotten ones.
Standard advice doesn’t always apply. A team of three running one Caddy instance in front of every service has a blast radius no bigger than a multi-name certificate would give it, so a wildcard is fine there. Air-gapped networks using an internal CA face the same logic with a worse risk. Internal wildcards for *.corp.internal are often issued with multi-year validity, which means a stolen key stays useful far longer than a public one would.
FAQ
Is a multi-domain SAN certificate safer than a wildcard?
Somewhat. A SAN certificate lists explicit names, so a stolen key can’t impersonate a name that isn’t listed. If you deploy the same SAN certificate to every host, though, the problem of shared keys is identical.
Do wildcards hide my subdomains from attackers?
CT logs show only *.example.com, so your hostnames don’t appear there. That’s obscurity, not protection. Passive DNS data, DNS brute-forcing and links in your own pages reveal most subdomains anyway.
A first check you can run today
Run the public key hash comparison across every host you know about and count the matches. If one key turns up in more than a handful of places, or anywhere you don’t control directly, split the wildcard apart before an incident forces you to do it within 24 hours.
