Skip to content
Detection · DNS

DNS Tunneling Log Analyzer

The firewall shows no outbound SSH, HTTPS or 8080 from a compromised server, yet data is still leaving. A common answer is DNS tunnelling: data hidden in the names a host looks up. Paste or drop your own DNS query logs and see which domains carry the signs (many unique, long, random-looking subdomains, TXT lookups, failed lookups, clock-like timing) and which host made the queries.

Everything is analysed in your browser: nothing is uploaded and no name in your log is looked up. For SOC analysts, threat hunters and incident responders.

Watch: DNS tunneling: data leaving one query at a time (1:31)
Chapters (5)
How DNS tunneling moves data out, the signs in your DNS logs, and what to block this week. AI-generated explainer. Not affiliated with any company named.

Drop log files

Zeek dns.log (TSV or JSON), BIND query logs, dnsmasq / Pi-hole, Windows DNS debug logs, CSV exports, or any text with one query per line.

Up to 5 files, 20 MB each. Uncompressed text only: unzip .gz logs first.

Ctrl/Cmd + Enter analyses. Nothing leaves your browser; no name is looked up.

Loading…

Sample report · illustrative data

Sample result: one hour of resolver logs, one domain stands out

A made-up Zeek dns.log of 212 queries from three workstations: ordinary browsing, plus a burst of TXT lookups from one host.

Summary

Queries parsed
212 from 215 lines (Zeek dns.log, TSV), 3 base domains
Verdicts
1 looks like tunnelling, 0 worth a look, 2 look normal

Domains, most suspicious first

Base domainScoreQueriesUnique subdomainsMean lengthEntropyTXT etc.Timing
example.net85 Looks like tunnelling12012088.14.67100%Fairly regular (0.36)
example.com0 Looks normal47515.01.402%Irregular (1.05)
example.org0 Looks normal45416.41.560%Irregular (0.99)

Why example.net scored 85

SignalPointsDetail
Many unique subdomains20/20120 unique subdomains; 100% of queries were for a name not seen before
Long names15/15mean name 88.1 characters, mean longest label 52.0
Random-looking characters (entropy)15/154.67 bits per character
Encoded-looking labels15/15100% of unique names (hex 0, base32 120, base64 0)
TXT, NULL, CNAME or MX lookups15/15100% of 120 typed queries
Failed lookups (NXDOMAIN)0/1017% of 120 answered queries
Regular timing (beacon-like)5/10coefficient of variation 0.36

Which hosts to look at

ClientQueriesSuspicious domains
192.0.2.23120example.net (85)
192.0.2.1054None
192.0.2.1138None

What to do

  • Find the process on 192.0.2.23 that made the TXT lookups (EDR or process DNS telemetry) before acting.
  • Sinkhole or block tunnel.example.net at your resolvers and keep the logs as evidence.
  • Make sure hosts can only use your internal resolvers, and block outbound DNS and DNS over HTTPS to everything else.

Made-up example data. Your own run uses your inputs. Downloads of the full report need Pro.

TL;DR

What this analyzer does

5 points
  • Paste or drop your own DNS query logs (Zeek dns.log, BIND, dnsmasq / Pi-hole, Windows DNS debug log, CSV or any one-query-per-line text) and see which domains look like data is being carried inside DNS names.
  • Every base domain gets a 0-100 score from seven documented signals: unique subdomains, name length, character entropy, encoded-looking labels, TXT/NULL/CNAME/MX share, NXDOMAIN share and regular timing.
  • A per-client table shows which host to look at first, and each domain opens to its longest example names and the points behind its score.
  • Runs entirely in your browser: nothing is uploaded, and no name in your log is looked up or contacted.
  • A high score is a lead, not proof; a low score does not clear a domain. Confirm on the endpoint before acting.

How data leaves when 22, 443 and 8080 are blocked

Blocking outbound ports stops direct connections, but most hosts can still ask a resolver to look up a name, and the resolver will forward that question across the internet to whichever name server is responsible for the domain. If someone controls that name server, the question itself is the message: data is cut into pieces, encoded into letters and digits, and placed in the subdomain part of each lookup. Answers, often TXT records, can carry instructions back. From the firewall's point of view, the server only talked to your own DNS resolver.

The same trick works with ICMP where ping is allowed out: data rides in the payload of echo requests and replies. And DNS over HTTPS wraps lookups inside ordinary HTTPS to an outside resolver, so they never appear in your resolver logs at all. This analyzer covers the DNS case you can see in query logs. For the network controls that close these paths, use the egress checklist linked below.

What the analyzer looks at

SignalPointsHow it is scored
Many unique subdomainsup to 2050+ unique subdomains with at least half of all queries unique: 20. 20+: 12. 10+: 5.
Long namesup to 15Mean longest label 40+ characters or mean name 80+: 15. Label 25+ or name 52+: 10. Label 16+ or name 40+: 5.
Random-looking characters (entropy)up to 15Mean Shannon entropy of the subdomain part 4.0+ bits per character: 15. 3.5+: 9. 3.0+: 4.
Encoded-looking labelsup to 15Half or more of unique subdomains carry a hex, base32 or base64-looking label of 16+ characters: 15. A fifth or more: 8.
TXT, NULL, CNAME or MX lookupsup to 15Half or more of queries (10+ queries, type known): 15. A fifth or more: 8.
Failed lookups (NXDOMAIN)up to 10Half or more of answered queries NXDOMAIN (10+ queries, answer code known for half): 10. A fifth or more: 5.
Regular timing (beacon-like)up to 10One client with 10+ timestamped queries whose gaps barely vary (coefficient of variation 0.25 or less): 10. 0.5 or less: 5.

60 or more reads “Looks like tunnelling”, 30 to 59 “Worth a look”, under 30 “Looks normal”. Domains with fewer than 10 queries are capped at 49. These weights are PlayCISO's own heuristic, not an industry standard: tune your production detections against your own baseline.

What it cannot tell you

  • Encrypted DNS is invisible here. Lookups sent with DNS over HTTPS or DNS over TLS to an outside resolver never reach your resolver's log.
  • Low and slow can score low. A channel that sends a handful of short queries an hour looks a lot like an update check.
  • A high score is a lead, not proof. Security products, CDNs, telemetry and DNS blocklist lookups also use long, random-looking names. Known noisy services are labelled, but that list is short and not exhaustive.
  • Base domains are approximate. A small built-in list of two-part suffixes (co.uk, com.au and similar) is used, not the full Public Suffix List.
  • The log decides what is scored. Without query types, answer codes or timestamps those signals stay at zero, and behind NAT or a forwarding resolver the “client” may be the resolver itself.

Where to get the logs

SourceWhat to turn on and what you get
Zeekdns.log on a sensor that sees DNS traffic: query, qtype_name, rcode_name, id.orig_h and ts are all used.
BINDQuery logging (the "queries" category). Gives client, name and type; no answer codes.
dnsmasq / Pi-holelog-queries (Pi-hole writes pihole.log). Reply lines give the NXDOMAIN share.
Windows DNS ServerDebug logging with packet direction, details and the question section. Response lines give answer codes.
Firewall, proxy or SIEMAny export with one query per line, or CSV with a header row naming the domain, client, type and status columns.

Resolver query logs are the best single source: they hold the name, type, answer code, client and time of every lookup. Keep enough history to hunt back to when a suspected compromise began. Nothing you drop here leaves your browser.

Frequently asked questions

How can data leave a server when outbound 22, 443 and 8080 are blocked?

Often through DNS. Almost every network lets hosts look up names, and a lookup for a name under a domain the attacker controls reaches the attacker's name server through your own resolvers. Data can be encoded into the subdomain labels of the query and replies can carry data back, for example in TXT records. ICMP (ping) can be abused the same way where it is allowed out. This is why DNS query logs matter even when the firewall looks tight.

Does this tool upload my DNS logs or look up the domains?

No. The file or pasted text is read and analysed in your browser. Nothing is sent to PlayCISO or anyone else, and no domain in your log is resolved, fetched or contacted.

Which log formats does it read?

Zeek dns.log in tab-separated form (with its #fields header) or JSON lines, BIND query logs, dnsmasq and Pi-hole logs, Windows DNS Server debug logs (the (3)www(7)example(3)com(0) name form is decoded), AdGuard Home JSON, CSV exports with a header row, and a generic mode for any text with one domain name per line. It detects the format, or you can choose it.

Does a high score mean we are being attacked?

No. It means the domain's queries look like the patterns tunnelling produces. Security products, CDNs, telemetry and DNS blocklist lookups also use long, random-looking names; the tool labels well-known ones as known noisy services, but that list is short. Find the process on the host that made the queries before you decide.

What can this analysis miss?

Queries sent over DNS over HTTPS or DNS over TLS to an outside resolver never reach your resolver logs. A slow tunnel that sends a few short queries an hour may score low. Logs without query types, answer codes or timestamps leave some signals blank. Use it with resolver controls and endpoint telemetry, not instead of them.

More tools like this

Related tools and labs, with new picks every day.

All tools
🎉 New here? Use code WELCOME10 for 10% off any plan at checkout