skip to content

Adversary C2 sits on the same CDN edge address as your payroll provider — how do you block it?

level: middleimportance: should knowfreq 44%

answer

  1. the address is not the target
  2. which layer still holds the name?
  3. five-tuple versus hostname
  4. sinkhole only sees questions asked
  5. allow-list the range, with a reason

basics

~20 s

Block at a layer that can see the name. A forward proxy sees the requested hostname or TLS SNI and can deny one service on a shared address; a firewall matches the address alone and would take payroll down too.

solid answer

~50 s

The address is not the target — the hostname is, and only some controls can tell them apart. An egress firewall matches the five-tuple, so denying that edge address denies payroll along with the C2. A forward proxy sees the CONNECT target or the TLS SNI before the tunnel is built, so it can deny one hostname on that address and pass the other. A DNS sinkhole also acts on the name, but only if the client asks: a hardcoded address, an external resolver or DNS-over-HTTPS bypasses it entirely. So I enforce the hostname at the proxy, put the shared range on a documented allow-list with an owner and a reason, and keep a detection on the address — because where SNI is absent or the client dials the address directly, the name-layer block is silently bypassed.

code

text · 3 lines
text
2026-08-24T09:04:11Z user=jlee action=ALLOWED method=CONNECT host=files.sync-vendor.example dst=203.0.113.42:443 bytes_out=41822931 cat=file-storage
2026-08-24T09:04:19Z user=mpatel action=ALLOWED method=CONNECT host=payroll.hr-vendor.example dst=203.0.113.42:443 bytes_out=18442 cat=business-apps
...

go deeper

for a junior

Be ready to say that one address can host many services, so a name-layer control is what separates the malicious tenant from your payroll provider. Know that a firewall matches addresses and ports only.

for a middle

Explain what each control on the path can see: five-tuple at the firewall, CONNECT target or TLS SNI at the proxy, the queried name at the resolver — and name the bypasses for each.

for a senior

Show the full package: name-layer enforcement, a documented allow-list entry for the shared range, and a retained detection on the address so a bypass is still visible.

for a principal

Own the estate-level consequence: if egress on some paths has no name-aware control, your intel can only ever be detection there, and that gap belongs in the risk conversation rather than being papered over with prefix blocks.

## The mistake this question is testing An indicator arrives as an address. Nothing about the address tells you it belongs to one tenant, and on modern hosting it usually does not. A single CDN edge or SaaS front end can terminate connections for thousands of customer hostnames, so 'block the address' and 'block the adversary' are different actions with different blast radii. The way out is to pick an enforcement point by **what it can see**. ## What each control on the path can actually see **Egress firewall.** Matches the five-tuple: source address, source port, destination address, destination port, protocol. That is the entire vocabulary. It cannot distinguish two hostnames sharing one address, because at that layer they are the same flow. Deny the address and both services die. **Forward proxy.** For plaintext HTTP it sees the request line and the Host header, so it can act on a full URL. For TLS it receives a `CONNECT host:443` request, and where clients connect transparently it reads the Server Name Indication field in the ClientHello. Either way it holds the **name** before the tunnel carries anything, so it can deny one hostname on a shared address. It does not see the body of an encrypted session unless it terminates TLS, which is a separate decision with its own consequences. **DNS sinkhole.** Acts on the name the client asked for and answers with an address you control. Clean separation of two tenants, and the sinkhole hit is itself a useful detection. Its weakness is that it only ever sees queries: an implant with a hardcoded address never asks, a client pointed at an external resolver asks somewhere else, and DNS-over-HTTPS hides the query inside a TLS session to a resolver you do not run. ## Reading the record Two proxy entries to the same destination address, one an exfiltration-sized upload through a sanctioned file-sync service and one an ordinary payroll session, is the whole problem in two lines. The `dst` field is identical; the `host` field is not. Only a control that keeps the `host` field can act on one and spare the other. ## What you enforce, and what you write down 1. **Enforce the name.** Push the hostname — or the full URL if you have it and the proxy supports path matching — into the proxy's destination list. This is the narrowest thing that stops the traffic. 2. **Allow-list the range explicitly.** Add the CDN or shared-hosting prefix to a maintained allow-list of things you will never deny at the address layer, each entry carrying an owner and a one-line reason. The point is not that you would not block it today; it is that six months from now a bulk push must hit a documented refusal rather than an accident. The engineer maintaining that list will never be able to enumerate every CDN range in existence, which is exactly why the entries need reasons rather than being a bare list of numbers. 3. **Keep a detection on the address.** Enforcement at the name layer is bypassable — no SNI, encrypted ClientHello, a direct-to-address connection, a different resolver. A flow or proxy detection on the address keeps you seeing contact even when the block does not fire, and its hits tell you whether the implant switched methods. 4. **Do not swap the block for blindness.** If you decide the collateral risk is too high to enforce at all on that path, the indicator must still be matched; declining to block is never declining to look. ## The directions to keep straight - A proxy deny on a hostname proves that a client asked for that name and was refused. It does not prove the client had no other route to the same destination. - An empty sinkhole log proves that no matching query reached your resolver. It does not prove the destination was never contacted. - A flow record to the shared edge address proves bytes moved to that address. It cannot tell you which tenant on that edge received them, because the record carries no payload and no name. That last point is why the address-layer detection is a supplement, not a verdict: it tells you to go and look at the proxy or endpoint record that still holds the name.

  • That egress path has no proxy — only the firewall. Now what?
    At layer 3 you cannot separate the two tenants, so an address block is a business outage you will lose the argument about. The options are to route that egress through a control that sees the name, to enforce at the endpoint or resolver instead, or to accept detection only and treat the address as a hunting lead. Blocking the prefix to catch one tenant is not one of the options.
  • The sinkhole never fired for that domain. What does that prove?
    Only that no matching query reached your resolver. The host may have used a hardcoded address, a public resolver, or DNS-over-HTTPS, all of which leave the sinkhole silent while the connection succeeds. Check flow and proxy records for the destination address before concluding there was no contact.
  • Why put the CDN range on an explicit allow-list instead of just never blocking it?
    So the decision survives the people who made it. A bare absence is invisible; a documented entry with an owner and a reason makes the collateral risk visible at review time and gives a future bulk push something to collide with. It also stops the range being quietly re-added when the same indicator reappears on a feed.

saying these in an interview costs you the question

  • Blocks the whole CDN prefix and calls it containment
  • Believes a firewall can distinguish two hostnames on one address
  • Treats an empty sinkhole log as proof of no contact
  • Assumes a proxy sees the encrypted request body without terminating TLS
  • Removes the block and leaves no detection behind

context