CyberKit

Exfiltration over DNS

Also called DNS exfil.

Smuggling data out by encoding it into DNS queries.

What it is

A technique that encodes stolen data into the labels of DNS queries to an attacker-controlled domain, whose name server reassembles it from the requests. DNS is rarely blocked outright, so the queries usually leave even tightly filtered networks.

Why it matters

DNS exfiltration evades many egress controls and content inspection because it abuses an essential, trusted protocol, so unusually long, high-volume, or high-entropy DNS lookups are key things to hunt.

In practice

Catching a steady stream of long, random-looking subdomain queries to one external domain, which chunks of a database leaving over DNS.

What to look for

  • Long, random looking subdomains.
  • High query volume to one domain.
  • TXT or NULL records requested from workstations.

Common mistake

Ignoring DNS because it is small. Steady queries add up to real data over time.

Practice it nearby

CyberKit has no tool for this term itself. These are the closest places to practice it.

In the field

Well-known tools where this shows up on the job. They are listed to show the landscape, not as a recommendation.

  • Wireshark Open source

    Opens a capture packet by packet so you can see exactly what crossed the wire. Our notes.

  • Zeek Open source

    Turns traffic into structured logs for connections, DNS, HTTP, TLS and more. Our notes.

  • Suricata Open source

    An IDS that alerts on known patterns and logs protocol metadata alongside. Our notes.

  • Arkime Open source

    Indexes full packet capture at scale so you can search and pull sessions later. Our notes.

Read next

Sources