DANE, short for DNS-based Authentication of Named Entities, is a protocol that lets a domain owner publish in the DNS which TLS certificate or public key a service is expected to present, protected by DNSSEC signatures. It is one of the mechanisms of internet trust that shifts part of the trust decision away from certificate authorities and toward the owner of the domain itself.
DANE is specified mainly in RFC 6698, with operational guidance in RFC 7671 and SMTP-specific rules in RFC 7672. Its strongest real-world adoption is in server-to-server email, where it protects SMTP connections against downgrade and interception attacks.
How DANE binds certificates to domain names
DANE works by publishing a TLSA record at a name derived from the service port and protocol, for example _25._tcp.mail.example.org for SMTP on port 25. A client that connects to the service looks up this record, verifies it with DNSSEC validation, and then compares the certificate received in the TLS handshake with the data in the record.
The security of the whole scheme rests on the DNSSEC chain of trust from the DNS root to the zone. Without valid signatures, a TLSA record is worthless, because an attacker able to forge DNS answers could also forge the expected certificate. Clients therefore ignore TLSA records in unsigned zones.
Each TLSA record has four fields. The table below explains what they control.
| Field | Values | Meaning |
|---|---|---|
| Certificate usage | 0 to 3 | Which certificate is matched and whether PKIX validation also applies |
| Selector | 0 or 1 | Match the full certificate or only its public key |
| Matching type | 0, 1 or 2 | Exact data, SHA-256 hash or SHA-512 hash |
| Association data | Hex string | The certificate, key or hash to compare against |
Certificate usage modes
The certificate usage field decides how DANE interacts with the traditional PKI. Two modes constrain the normal certificate authority system, and two modes allow the domain owner to act as its own trust anchor. Choosing the right mode is the most important configuration decision.
| Usage | Name | Effect | Typical use |
|---|---|---|---|
| 0 | PKIX-TA | Requires a specific CA in a normally valid chain | Restricting which CA may issue |
| 1 | PKIX-EE | Requires a specific end-entity certificate in a valid chain | Rare in practice |
| 2 | DANE-TA | Names the domain’s own trust anchor, no public CA needed | Private CAs, SMTP |
| 3 | DANE-EE | Matches the server certificate or key directly | Most common for SMTP |
For SMTP, RFC 7672 recommends DANE-EE (3) or DANE-TA (2), because mail servers do not share a common set of trusted root certificates. The combination 3 1 1, meaning DANE-EE with a SHA-256 hash of the public key, is the most widely deployed record because it survives certificate renewal when the key stays the same.
DANE compared with related trust mechanisms
DANE addresses a weakness of the classic certificate authority model: any trusted CA can issue a certificate for any domain. Other mechanisms tackle the same problem differently, and they are often complementary rather than competing.
| Mechanism | Where trust comes from | Main strength | Main limitation |
|---|---|---|---|
| DANE | DNSSEC-signed DNS zone | Owner controls accepted keys | Requires DNSSEC end to end |
| Certificate authority PKI | Browser and OS root stores | Universal client support | Mis-issuance by any CA |
| MTA-STS | HTTPS policy plus CA certificates | Works without DNSSEC | Trust on first use |
| CAA records | DNS record read by CAs | Limits which CA may issue | Not checked by clients |
| Certificate transparency | Public append-only logs | Detects mis-issuance | Detects after the fact |
In email, MTA-STS and DANE coexist: many large providers publish MTA-STS, while operators with signed zones prefer DANE because it is not vulnerable to first-contact downgrade. Sending servers that support both apply DANE when valid TLSA records exist.
Deploying DANE for email servers
A DANE deployment for SMTP requires DNSSEC on the zones of the MX hosts, TLSA records for each MX host on port 25, and a mail server that offers STARTTLS with the matching certificate. Senders that validate DANE then refuse to deliver mail in cleartext or to a server presenting the wrong certificate.
- Sign the zone with DNSSEC and confirm the DS record at the parent zone.
- Generate the TLSA record from the current key, for example as a 3 1 1 record.
- Publish the record for every MX host and wait for the old TTL to expire.
- Test with validating tools before relying on the record.
- Automate key rollover so a new record is published before the new key goes live.
The rollover rule is essential: publish the next key’s TLSA record in advance, keep both records during the transition, and remove the old one only after the new certificate is active. Automated certificate renewal through ACME can generate new keys silently, so many operators reuse the key on renewal or hook the renewal process into DNS updates.
Limitations and failure modes
DANE’s main barrier is limited client support on the web. Major browsers do not validate TLSA records, partly because DNSSEC answers are often unavailable to end-user devices and an additional DNS lookup adds latency. As a result, DANE today matters mostly for SMTP, XMPP and some private deployments.
| Failure | Cause | Result |
|---|---|---|
| Stale TLSA record | Key replaced without updating DNS | Validating senders defer mail |
| Broken DNSSEC chain | Expired signatures or wrong DS record | TLSA treated as bogus |
| Missing record on one MX | Incomplete rollout | Inconsistent delivery behavior |
| Usage mode mismatch | PKIX mode used for SMTP | Validation fails on some senders |
Because a wrong record causes hard delivery failures rather than warnings, monitoring is mandatory. Operators should check TLSA records against the live certificate after every change and alert on DNSSEC signature expiry well before it happens.
Explained without jargon
When two computers start an encrypted conversation, one shows a digital ID card called a certificate. Normally, a company called a certificate authority vouches for that card. DANE lets the owner of a domain write down in the address book of the internet which ID card is genuine, and seal that entry so nobody can alter it.
A visitor can then compare the card it receives with the sealed entry. If they do not match, the connection stops instead of trusting an impostor. It is like a building posting a signed photo of its real receptionist at the entrance.
A typical use case
A university runs its own mail servers for 30,000 users and already signs its DNS zone with DNSSEC. The IT team publishes a 3 1 1 TLSA record for each of its two MX hosts, generated from the public key of the server certificate. Large European mail providers that validate DANE now refuse to send mail to the university in cleartext and reject any server that presents a different key.
When certificates are renewed every 60 days, the renewal script keeps the same key pair, so the TLSA record stays valid. Once a year the team rotates the key: it publishes the new record a week in advance, keeps both records during the switch and removes the old one afterward. Monitoring confirms that no message was deferred during the rollover, and an intercepted connection attempt on a misconfigured campus network fails safely instead of leaking mail.