<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Tirveni Yadav on Medium]]></title>
        <description><![CDATA[Stories by Tirveni Yadav on Medium]]></description>
        <link>https://medium.com/@yadav.tirveni?source=rss-7e59c140b0d9------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*dmbNkD5D-u45r44go_cf0g.png</url>
            <title>Stories by Tirveni Yadav on Medium</title>
            <link>https://medium.com/@yadav.tirveni?source=rss-7e59c140b0d9------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 19:43:59 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@yadav.tirveni/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Every Firewall Change Shouldn’t Be a Support Ticket]]></title>
            <link>https://medium.com/@yadav.tirveni/every-firewall-change-shouldnt-be-a-support-ticket-9997ae7b89da?source=rss-7e59c140b0d9------2</link>
            <guid isPermaLink="false">https://medium.com/p/9997ae7b89da</guid>
            <category><![CDATA[network-security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[firewall]]></category>
            <category><![CDATA[datacenter-solutions]]></category>
            <category><![CDATA[isp]]></category>
            <dc:creator><![CDATA[Tirveni Yadav]]></dc:creator>
            <pubDate>Thu, 17 Sep 2026 05:24:35 GMT</pubDate>
            <atom:updated>2026-09-17T05:24:35.872Z</atom:updated>
            <content:encoded><![CDATA[<p>If you run network infrastructure for other people — a datacenter, an ISP, a hosting provider — you already know this conversation by heart:</p><blockquote>“Someone’s hitting my server. Can you block this IP for me? Right now, please.”</blockquote><p>For you, it’s routine. For your customer, it’s the worst possible way to handle an active incident: file a ticket, wait, hope someone’s awake, hope they get to it before whatever’s happening gets worse. Multiply that by every customer who has this exact moment at 2am on a weekend, and you have a support queue that’s constantly on fire for a problem that has nothing to do with your infrastructure and everything to do with theirs.</p><p>We build<a href="https://cloudarmour.io/products/neurowall.html"> Neurowall</a>, a network defense platform we run in front of customer infrastructure at datacenter and ISP scale. This is about a feature we added because we kept living this exact problem from both sides of the ticket.</p><p><strong>The problem, from the ISP’s side</strong></p><p>Every network operator selling connectivity or hosting eventually runs into the same wall: your customers need firewall changes far more often than your team can comfortably handle them.</p><ul><li><em>It doesn’t scale with your customer count</em>. Ten customers asking for occasional IP blocks is a Tuesday. A thousand customers doing the same is a dedicated headcount problem you didn’t budget for.</li><li><em>It’s not actually your problem to solve, but you’re the one solving it.</em> A customer wanting to block a specific attacker’s IP from reaching `their own` server is a decision about `their` risk tolerance, not yours — yet your NOC is the one making the change, at 2am, for someone else’s incident.</li><li><em>Slow turnaround erodes trust exactly when it matters most</em>. The moment a customer is under active attack is the worst possible moment to also be waiting on a support ticket. A slow response to “please block this IP” doesn’t feel like good service — it feels like being abandoned mid-incident.</li><li><em>It’s a cost center with no upside</em>. Every hour your engineers spend making one-line firewall changes for customers is an hour not spent on your own infrastructure, your own product, your own growth.</li></ul><p><strong>It’s the same story for datacenters, not just ISPs</strong></p><p>This isn’t only an ISP problem. Datacenters and hosting providers live an almost identical version of it, just with a different customer profile. A colocation customer with their own rack and their own public IP block wants the same thing a broadband ISP’s customer wants: the ability<br>to block an attacker on their own equipment without opening a ticket and waiting.</p><p>A dedicated server or bare-metal hosting provider has customers running everything from gaming servers to trading infrastructure — workloads that are frequent, high-profile DDoS targets, and where every minute of exposure has a real cost. In a shared facility, a provider also can’t just hand a customer generic admin access to “the firewall” — whatever self-service looks like, it has to be scoped so tightly to that one customer’s own slice that neighboring tenants in the same facility are never even visible, let alone reachable.</p><p>The operational pain, the customer frustration, and<br>the isolation requirement are the same whether the entity running the infrastructure calls itself an ISP or a datacenter — which is exactly why this isn’t a niche fix for one kind of provider.</p><p><strong>The problem, from the customer’s side</strong></p><p>Flip it around, and it’s just as frustrating from the other seat:</p><ul><li><em>You can see the attack, but you can’t do anything about it.</em> You know exactly which IP is hammering your service. You just can’t touch the firewall that’s actually positioned to stop it — that’s on your provider’s side of the fence.</li><li><em>Every change goes through someone else’s queue, on someone else’s schedule.</em> Even a responsive provider adds latency you don’t control, at the exact moment latency matters most.</li><li><em>You have no visibility into your own protection.</em> Is the rule from three weeks ago still there? Did it actually get applied? You’re trusting a black box, not managing your own security posture.</li><li><em>This is table stakes everywhere else in tech. </em>Anyone who’s used a modern cloud platform expects to manage their own security groups, their own access rules, in real time, themselves.<br> A ticket-based firewall change feels like a step backward the moment you compare it to anything cloud-native.</li></ul><p><strong>What changes when customers can act for themselves</strong></p><p>NeuroWall now lets an ISP or datacenter operator hand customers a self-service dashboard for <em>their own</em> slice of the network — nothing more, nothing less. A customer logs in, sees the IP ranges that belong to them, and can add or remove their own block/allow rules immediately, no<br>ticket required.</p><p><strong>What that actually changes:</strong></p><ul><li><em>Incident response time drops from “whenever support gets to it” to “right now.”</em> The person best positioned to know they’re under attack — the customer — is also the person who can act on it, immediately, without a human in the loop.</li><li><em>Support load drops for the provider.</em> The most repetitive category of ticket — “please change my firewall rule” — mostly stops existing. Your team gets its time back for problems that actually need an expert.</li><li><em>It becomes a product feature, not just an operational fix</em>. Self-service security control is increasingly what customers `expect` from infrastructure providers, the same way self-service DNS or self-service billing became expected rather than exceptional. Providers offering it have a real differentiator against providers still running everything through a ticket queue.</li><li><em>Customers get real, immediate control without an inch of extra exposure to the provider’s core systems.</em> Self-service here means each customer’s world is strictly their own — no visibility into anyone else’s rules, no access to anything beyond what’s theirs. Handing over convenience doesn’t mean handing over risk.</li></ul><p><strong>The bigger shift</strong></p><p>This is really a small instance of a larger pattern: security and networking infrastructure is slowly catching up to how self-service everything else in cloud infrastructure already became. <br>Compute, storage, DNS, billing — all self-service today, all ticket-based a decade ago. Firewall management for a provider’s own customers has lagged behind that shift, mostly because getting the isolation right is genuinely hard to trust. Getting it right is what turns “we’d like to offer this” into something a provider is actually comfortable shipping.</p><p><em>If you operate infrastructure for other people and this is a problem you’re living with too, I’d like to hear how you’re currently handling it.</em></p><p><a href="https://cloudarmour.io/products/neurowall.html">Neurowall</a></p><p><a href="https://cloudarmour.io/">CloudArmour</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9997ae7b89da" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Reading a TLS ClientHello From Kernel Space, Byte by Byte]]></title>
            <link>https://medium.com/@yadav.tirveni/reading-a-tls-clienthello-from-kernel-space-byte-by-byte-83f0fe777a1c?source=rss-7e59c140b0d9------2</link>
            <guid isPermaLink="false">https://medium.com/p/83f0fe777a1c</guid>
            <category><![CDATA[tls]]></category>
            <category><![CDATA[ebpf]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[Tirveni Yadav]]></dc:creator>
            <pubDate>Thu, 27 Aug 2026 06:41:00 GMT</pubDate>
            <atom:updated>2026-08-27T06:41:00.966Z</atom:updated>
            <content:encoded><![CDATA[<p>Parsing a TLS ClientHello is, on paper, one of the more approachable pieces of binary parsing you’ll ever do. The wire format is public, well documented, and straightforward to walk sequentially. If you were writing this in Python, you’d slice a byte string a dozen times and be done in twenty lines.</p><p>Vaanvil parses ClientHellos inside an eBPF program attached to a TC classifier, running in kernel space, on live traffic. The wire format is identical to the Python version. The code that reads it looks nothing alike. The differences aren’t stylistic. They’re what happens when every packet access, every offset derived from untrusted input, and every loop has to satisfy the eBPF verifier before the program is allowed anywhere near live traffic.</p><h4>The shape you’re looking for</h4><p>Strip away the TCP framing and a TLS ClientHello, sitting inside a handshake record, looks roughly like this:</p><pre>[TLS record header: 5 bytes]<br>  content_type       (1 byte)   — 0x16 for Handshake<br>  version            (2 bytes)<br>  length             (2 bytes)<br><br>[Handshake header: 4 bytes]<br>  msg_type            (1 byte)   — 0x01 for ClientHello<br>  length              (3 bytes)<br><br>[ClientHello body]<br>  client_version      (2 bytes)<br>  random              (32 bytes)<br>  session_id_len      (1 byte)<br>  session_id          (variable, session_id_len bytes)<br>  cipher_suites_len   (2 bytes)<br>  cipher_suites       (variable)<br>  compression_len     (1 byte)<br>  compression_methods (variable)<br>  extensions_len      (2 bytes)<br>  extensions          (variable — sequence of type/length/value records)</pre><p>Each extension is itself:</p><pre>type (2 bytes) | length (2 bytes) | data (length bytes)</pre><p>The one Vaanvil actually cares about for policy decisions is `server_name`, extension type `0x0000`. Its payload contains a length-prefixed list of server names, including the hostname normally exposed as SNI.</p><p>That’s the basic shape. Everything interesting about Vaanvil’s parser comes from the environment in which it has to read those bytes.</p><h4>Packet access at TC isn’t pointer walking</h4><p>If you’ve read an XDP program, you’ve probably seen something like this:</p><pre>struct ethhdr *eth = (struct ethhdr *)(long)ctx-&gt;data;<br><br>if ((void *)(eth + 1) &gt; (void *)(long)ctx-&gt;data_end)<br>    return XDP_DROP;</pre><p>The program derives a pointer from `ctx-&gt;data`, proves the structure fits before `data_end`, and then dereferences it. XDP makes this style particularly natural because the program is operating very early in the receive path against the packet buffer exposed by the XDP context.</p><p>TC is a different environment. A TC classifier works with a `struct __sk_buff`, and an skb can have a more complicated underlying representation than the simple linear-buffer model you want when writing a binary parser. TC programs *can* use verifier-approved direct packet access in supported cases, but Vaanvil deliberately doesn’t build its TLS parser around that assumption.</p><p>Instead, it uses offset-based reads through a helper:</p><pre>static __always_inline int skb_read(struct __sk_buff *skb, __u32 offset,<br>                                     void *dst, __u32 len)<br>{<br>    if (len == 0)<br>        return -1;<br><br>    if (bpf_skb_load_bytes(skb, offset, dst, len) &lt; 0)<br>        return -1;<br><br>    return 0;<br>}</pre><p>`bpf_skb_load_bytes()` copies `len` bytes starting at an offset in the skb into a buffer owned by the program. The helper performs the runtime bounds handling required for the read and returns an error if the requested bytes aren’t available.</p><p>That gives Vaanvil a consistent access model regardless of how the skb happens to be represented underneath. Every field in the kernel-side parser follows this pattern: TCP fields, TLS record type, handshake type, length prefixes, extension headers, and eventually the hostname. It’s more verbose than walking pointers through a byte array. It’s also considerably easier to reason about when every read originates from untrusted network input.</p><h4>Every field earns its own bounds check</h4><p>Here’s the shape of the real code that reads the session ID length and advances past the session ID:</p><pre>__u8 session_id_len = 0;<br><br>if (skb_read(skb, off, &amp;session_id_len,<br>             sizeof(session_id_len)) &lt; 0)<br>    return -1;<br><br>if (session_id_len &gt; 64)<br>    return -1;<br><br>off += 1 + session_id_len;<br><br>if (off &gt; parse_end)<br>    return -1;</pre><p>That’s several lines just to advance past one variable-length field. The same pattern repeats for cipher suites, compression methods, extension lengths, and the structures nested inside individual extensions. There are really two kinds of validation happening here. The first is <em>protocol validation</em>: does this value make sense for the structure we’re parsing? The second is <em>verifier-friendly range narrowing</em>: after this value influences an offset, can the verifier still prove that subsequent operations remain within a safe range? That distinction matters.</p><p>From the verifier’s perspective, a length byte read from a network packet isn’t “probably small.” It’s an untrusted scalar with a range that has to be tracked through every operation that follows.</p><p>Checks such as:</p><pre>if (session_id_len &gt; 64)<br>    return -1;</pre><p>turn an attacker-controlled value into something with an explicit upper bound.</p><p>There may be multiple ways to structure the code so the verifier can establish safety. The important part isn’t that this exact check is magical. It’s that values derived from packet contents have to be narrowed early enough that every later offset and memory operation remains provably bounded. That’s the real texture of writing parsers in eBPF. The safety checks aren’t comments about your intentions. They’re facts the verifier can use.</p><h4>The loop that can only look at eight things</h4><p>Extensions are a variable-length sequence, so eventually the parser has to iterate through them looking for `server_name`.</p><p>Vaanvil does this:</p><pre>#pragma unroll<br>for (int i = 0; i &lt; 8; i++) {<br>    __u32 ext_hdr_end = off + 4;<br><br>    if (ext_hdr_end &lt; off || ext_hdr_end &gt; ext_end)<br>        break;<br><br>    __u16 ext_type = 0, ext_len = 0;<br><br>    if (skb_read(skb, off, &amp;ext_type,<br>                 sizeof(ext_type)) &lt; 0)<br>        return -1;<br><br>    if (skb_read(skb, off + 2, &amp;ext_len,<br>                 sizeof(ext_len)) &lt; 0)<br>        return -1;<br><br>    ext_type = bpf_ntohs(ext_type);<br>    ext_len = bpf_ntohs(ext_len);<br>    off += 4;<br><br>    __u32 ext_payload_end = off + ext_len;<br><br>    if (ext_payload_end &lt; off ||<br>        ext_payload_end &gt; ext_end)<br>        break;<br><br>    if (ext_type == TLS_EXT_SERVER_NAME) {<br>        // ... extract and return the hostname ...<br>    }<br><br>    off = ext_payload_end;<br>}<br><br>return -1; // SNI not found</pre><p><em>#pragma unroll</em> asks the compiler to expand the loop into a fixed number of iterations at compile time.</p><p>Historically, this style was extremely common in eBPF because older verifier generations placed severe restrictions on loops. Modern kernels support bounded loops, and mechanisms such as `bpf_loop()` provide additional options for workloads that need dynamic iteration. Vaanvil still uses a fixed, fully unrolled loop here.</p><p>Why?</p><p>Because the verifier’s termination argument becomes trivial: there can be at most eight iterations. It also keeps the parser’s behavior predictable across the kernels the project targets and puts an explicit ceiling on how much work a malicious ClientHello can force the kernel program to perform. But that simplicity has a very real consequence.</p><h4>The kernel parser examines at most the first eight extensions.</h4><p>If `server_name` is extension number nine, Vaanvil’s kernel parser doesn’t find it. Not because the ClientHello is malformed. Not because the packet couldn’t be read. The parser simply reached the amount of work it had agreed to perform. In practice, common TLS clients tend to place SNI early enough that this works well for the traffic Vaanvil was designed around. But “in practice” is doing real work in that sentence. A ClientHello with an unusual extension ordering is a legitimate case where the bounded kernel parser can miss SNI.</p><p>That’s not a hypothetical limitation hidden by the implementation. It’s a deliberate architectural boundary: eight iterations were chosen to balance useful coverage against verifier complexity, instruction count, and bounded per-packet work.</p><h4>The 64-byte hostname buffer</h4><p>Once Vaanvil finds the `server_name` extension, it eventually reaches another explicit boundary:</p><pre>if (sn_len &gt; 63)<br>    sn_len = 63;</pre><p>The destination buffer is 64 bytes.</p><p>A complete DNS hostname can be considerably longer than 63 bytes, so this isn’t a statement that 63 bytes is the maximum valid SNI hostname. It’s a statement about how much hostname data this particular kernel-side representation is willing to carry. If the SNI value is longer, the kernel parser preserves only the portion that fits. That has semantic consequences.</p><p>Two long hostnames sharing the same stored prefix could become indistinguishable if a policy decision relied exclusively on this truncated representation. So the 64-byte buffer shouldn’t be understood as a complete representation of every possible hostname. It’s another boundary between what Vaanvil asks its kernel program to do and what it deliberately leaves to a less constrained environment. And that distinction leads to the more important architectural point.</p><p>Conceptually, the pipeline looks like this:</p><pre>Live packet<br>    ↓<br>TC / eBPF<br>    ↓<br>Bounded ClientHello inspection<br>    ↓<br>Captured data / metadata<br>    ↓<br>Userspace<br>    ↓<br>Go re-parser<br>    ↓<br>Policy / control-plane logic</pre><p>The kernel program does the work that benefits from happening close to the packet path while operating under strict, verifier-friendly limits. The userspace side doesn’t live under those same constraints. A Go re-parse of captured ClientHello data can use ordinary slices, dynamic loops, larger data structures, and substantially more flexible parsing logic. There’s no `#pragma unroll`, no tiny eBPF stack budget, and no verifier trying to prove every possible execution path before the program starts. This changes how the eight-extension cap and the hostname buffer should be interpreted. They’re not claims that eight extensions or 63 hostname bytes describe the full TLS protocol. They’re limits on how much work Vaanvil is willing to perform in its kernel fast path. That is a much more useful distinction.</p><h4>Bounded work is part of the security model</h4><p>It’s tempting to look at all these constraints and see only compromises. Why not support every extension? Why not allocate enough space for the longest possible hostname? Why not keep parsing until you reach the end? In userspace, those might be perfectly reasonable questions. Inside an eBPF program running against attacker-controlled packets, bounded work is itself a feature. The attacker controls the packet. They control the length fields. They control extension ordering. They can deliberately construct malformed nested structures. And they can send those structures repeatedly.</p><p>So a parser in this position needs more than functional correctness. It needs a predictable ceiling on what one packet can make it do. The fixed extension count, explicit length bounds, checked offset arithmetic, fixed-size buffers, and helper-mediated reads all contribute to that property. The parser doesn’t try to understand everything. It tries to understand enough while making the amount of work an attacker can demand predictable.</p><h4>What all of this buys you</h4><p>None of this is how you’d write a ClientHello parser in a normal application. The userspace Go parser later in Vaanvil’s pipeline looks much more like the implementation you’d expect: dynamic loops, slices, ordinary data structures, and none of the strange-looking contortions required to satisfy the eBPF verifier. The kernel parser is different because its job is different. Every value derived from the wire is treated as hostile. Every offset has to remain bounded. Every packet access has to be safe. Every loop has to terminate within a range the verifier can establish. And the amount of work one malicious packet can force the program to perform has an explicit ceiling.</p><p>That’s harder to write. It’s often uglier to read.And it forces you to draw boundaries that a userspace parser wouldn’t need.But those constraints buy something important: before the program is attached to live traffic, the verifier can establish critical safety properties about its memory accesses and execution paths. That’s the trade.</p><p>Vaanvil doesn’t try to make kernel-space TLS parsing look like userspace parsing. It divides the problem instead</p><p><em>Do bounded, predictable inspection in the kernel. Do flexible, complete parsing in userspace. And make the boundary between the two explicit.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=83f0fe777a1c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[XDP vs TC: Why Vaanvil Chose the Slower Hook]]></title>
            <link>https://medium.com/@yadav.tirveni/xdp-vs-tc-why-vaanvil-chose-the-slower-hook-66c26306df1f?source=rss-7e59c140b0d9------2</link>
            <guid isPermaLink="false">https://medium.com/p/66c26306df1f</guid>
            <dc:creator><![CDATA[Tirveni Yadav]]></dc:creator>
            <pubDate>Mon, 17 Aug 2026 06:01:01 GMT</pubDate>
            <atom:updated>2026-08-17T06:01:01.652Z</atom:updated>
            <content:encoded><![CDATA[<p>If you’ve spent any time around eBPF networking talks, you’ve heard the pitch for XDP: it runs at the earliest possible point in the receive path, sometimes directly in the NIC driver, before the kernel has even allocated a `sk_buff` for the packet. Drop a packet at XDP and you’ve spent a few hundred nanoseconds. Drop it anywhere else and you’ve already paid for memory allocation, and possibly a chunk of the network stack, before the kernel even asks your program what to do.</p><p>So when I tell people that Vaanvil — a kernel-level L7 firewall built to inspect TLS ClientHellos and enforce policy in real time — attaches its packet-inspection logic almost entirely through TC (traffic control) classifiers, not XDP, the first reaction is usually some version of ”<em>why would you leave that performance on the table?</em>”</p><p>The honest answer is: because the fastest hook in Linux’s networking stack isn’t the right one for every job, and this is one of the clearer cases where “fastest” and “correct” pull in different directions.</p><h4>1. The bigger reason: XDP can’t see the traffic leaving</h4><p>Here’s the part that actually settled the decision for Vaanvil, and it’s less about performance than about what XDP can physically observe.</p><p>Vaanvil needs to see TLS handshakes in both directions. When the machine it’s running on originates a connection — the common case in a lot of the deployments this project targets — the ClientHello leaves via <em>egress</em>. XDP has no hook there. It cannot see it. Full stop.</p><p>TC’s `clsact` doesn’t have this limitation. A single qdisc gives you an ingress classifier and an egress classifier, sharing infrastructure, attached in one operation. Once you’ve accepted that you need TC for the egress side no matter what, you have two options: split your parsing logic across two different eBPF program types with two different context structures and two different mental models (XDP for ingress, TC for egress), or write it once, in one program type, and attach it in both directions. Vaanvil does the latter — the actual attach path loads TC ingress and TC egress classifiers on the same interface, plus a second TC hook specifically to observe outbound ClientHellos on egress.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*H_Y1fXqUxmCZ6gCPDK2K6Q.png" /><figcaption>Transmit path</figcaption></figure><p>Maintaining one parsing pipeline instead of two isn’t just a style preference. Every eBPF program you write has to independently satisfy the verifier, independently manage its own stack budget, and independently stay correct as the wire format details change. Two copies of TLS-record parsing logic, one for `xdp_md` and one for `__sk_buff`, is two places for a subtle byte-offset bug to hide — and this codebase has plenty of scar tissue from exactly that class of bug already, without doubling the surface area on purpose.</p><h4>2. The problem: a ClientHello doesn’t always fit in one packet</h4><p>A ClientHello is not guaranteed to fit in a single Ethernet MTU, particularly as extension payloads grow. That means the record you actually care about parsing may be split across multiple physical packets on the wire.</p><p>At the XDP hook, in native mode, you’re liable to see those as separate invocations of your program, each with a fragment of the handshake. Reassembling that yourself, inside an eBPF program, under the verifier’s constraints, for every new TLS connection, is exactly the kind of complexity XDP was not designed to make easy — there’s no connection-tracking or reassembly primitive sitting there waiting for you.</p><p>By the time a TC ingress classifier runs, GRO has often already done that coalescing work for you. (<em>In practice, that often gives the parser more contiguous TLS payload to work with than XDP does. It isn’t TCP stream reassembly, and a ClientHello can still span multiple skbs, but it reduces the amount of fragmentation the fast path has to deal with</em>.) Hence, the ClientHello is much more likely to show up as one contiguous, parseable region in a single invocation. This is one of the more concrete, unglamorous reasons TC gets chosen over XDP for anything doing real application-layer parsing rather than pure header inspection: you’re trading a bit of packet-processing latency for a network stack that’s already done some of your reassembly homework.</p><h4>3. Two hooks, two very different vantage points</h4><p><em>XDP</em> (eXpress Data Path) runs as early as the driver will let it. In native/driver mode, your program sees a raw packet buffer before the kernel has built any of the metadata structures the rest of the networking stack relies on. It’s receive-only — there is no shipped, general-purpose “XDP egress” hook in upstream Linux. You get an `xdp_md` context: pointers to packet data, and not much else. The tradeoff for that speed is that you’re also earlier than GRO (Generic Receive Offload), the mechanism that coalesces a burst of physically-received packets into one larger, contiguous buffer before handing it up the stack. At the XDP hook, you might be looking at one MTU-sized fragment of something bigger.</p><p>TC ingress (via the ‘clsact’ qdisc) runs late enough for ingress that GRO may already have coalesced multiple TCP segments into a larger skb. In practice, that often gives the parser more contiguous TLS payload to work with than XDP does. It isn’t TCP stream reassembly, and a ClientHello can still span multiple skbs, but it reduces the amount of fragmentation the fast path has to deal with. Crucially, <em>`clsact`</em> gives you <em>both</em> directions: a TC ingress classifier and a TC egress classifier, attached to the same qdisc on the same interface, seeing traffic on its way in and on its way out.</p><p>For pure “look at this packet, drop or pass it” logic — rate limiting, IP blacklists, SYN flood mitigation — XDP’s earliness is close to pure upside. You’re doing bounded, single-packet work, and getting it over with as cheaply as possible matters a lot when you’re absorbing a flood.</p><p>Vaanvil isn’t doing that kind of work in its main path. It’s trying to read a TLS ClientHello.</p><h4>The interesting wrinkle: the XDP program still exists</h4><p>Here’s the detail that I think makes this more than a theoretical tradeoff discussion. Vaanvil actually ships a real, working XDP program — a genuinely useful one, doing IP blacklist lookups and SYN-flood detection at the earliest possible point. It’s compiled, it’s small (a few hundred verified instructions, tiny next to the TC programs’ tens of thousands), and it gets <em>loaded</em> into the kernel every time the daemon starts.</p><p>It’s just never <em>attached</em>.</p><figure><img alt="XDP: cheap L3/L4 rejection -&gt; TC: state/context-dependent inspection ↓-&gt; userspace/control plane: policy" src="https://cdn-images-1.medium.com/max/1024/1*Fx-NCaQJ5bzZJeo5t2HBOA.png" /><figcaption>Flow: XDP -&gt; TC -&gt; Userspace</figcaption></figure><p>Loading an eBPF program and attaching it to a hook are two separate steps in the kernel’s model — loading verifies and stages the bytecode; attaching is what actually puts it in a packet’s path. Vaanvil’s runtime startup code loads every program in its compiled object, including the XDP one, but the function responsible for wiring hooks to interfaces only ever calls the TC-attach paths. The XDP fast-path sits there, fully built, fully verified, doing nothing, on every single run.</p><p>That’s not an oversight so much as a design decision left visibly half-finished: the architecture keeps a door open for a hybrid model — XDP doing high-volume, low-context filtering (blacklists, flood mitigation) as a genuine fast path, with TC handling everything that needs to actually understand a TLS handshake — without anyone having yet decided the extra deployment complexity of managing two attach points is worth it over what TC alone already provides.</p><h4>The actual lesson</h4><p>&quot;XDP is faster” is true, and also not the only question worth asking. The right question is what your program needs to <em>see</em>. If you’re making a bounded decision from a single packet’s headers, XDP’s earliness is close to free performance. If you need multiple packets’ worth of context, or you need to watch a connection in both directions, you’re going to end up at TC (or somewhere even later) regardless of how much raw speed you’re leaving on the table — because the alternative isn’t “TC,but faster.” It’s considerably more state, complexity, and duplicated machinery to recover context that TC already gives us.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LXNIMy3fwMN79xI7F6RA9w.png" /><figcaption>Comparison: XDP vs TC</figcaption></figure><p>Vaanvil’s TC-only attach path isn’t a rejection of XDP’s value. It’s what happens when you actually need reassembled, bidirectional context to do your job, and you’d rather have one correct parsing pipeline than two fast, incomplete ones.</p><p><a href="https://cloudarmour.io/products/vaanvil.html">Vaanvil</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=66c26306df1f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What does a 31.4 Tbps attack tell defenders about how DDoS has changed?]]></title>
            <link>https://medium.com/@yadav.tirveni/what-does-a-31-4-tbps-attack-tell-defenders-about-how-ddos-has-changed-cf21b6302c5b?source=rss-7e59c140b0d9------2</link>
            <guid isPermaLink="false">https://medium.com/p/cf21b6302c5b</guid>
            <category><![CDATA[ddos]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[Tirveni Yadav]]></dc:creator>
            <pubDate>Mon, 10 Aug 2026 10:29:48 GMT</pubDate>
            <atom:updated>2026-08-10T10:29:48.822Z</atom:updated>
            <content:encoded><![CDATA[<p>A deep dive into record-breaking botnet assaults, shifting attack patterns, resulting in traditional defenses are failing</p><p><strong>Introduction</strong></p><p>In Q4 2025, the internet witnessed a new record: a <em>31.4 Tbps DDoS attack</em>— the largest ever documented. This wasn’t a worst-case scenario being discussed at security conferences. And it’s likely just the beginning.</p><p>The Threat Report, paints a sobering picture of how the DDoS landscape has evolved. The report reveals a <em>fundamental shift</em> in attacker tactics, botnet sophistication, and the technologies behind the assault.</p><p>These findings are unsettling for security teams. This is wake up call for organizations still relying on legacy defenses.</p><p><strong>The 31.4 Tbps Attack: Scale Without Precedent</strong></p><p><em>What Happened</em></p><p>In Q4 2025, a single DDoS attack reached <em>31.4 Tbps</em>.</p><p>- 31.4 Tbps = enough traffic to saturate 31,400 standard 1 Gbps internet connections simultaneously<br>- Previous record (2023): ~21.3 Tbps<br>- Growth rate: ~50% increase in peak attack volume in just 2 years</p><p>This was real traffic, hitting real infrastructure, overwhelming defenses which were state-of-the-art just months earlier.</p><p><em>Who Launched It?</em></p><p>The attack was probably orchestrated by botnets such as:</p><p>- Kimwolf: A successor to the notorious Aisuru botnet, with 550+ command-and-control (C2) nodes identified and later null-routed by upstream ISPs<br>- Distributed IoT/Linux botnets: Compromised routers, webcams, smart TVs, and unpatched servers globally<br>- Rental infrastructure: Attackers increasingly temporary lease botnet access through underground forums instead of building their own</p><p>The attackers needed<em> scale and persistence</em>.</p><p><strong>Why Packet Rate Matters More Than Bandwidth</strong></p><p>When headlines mention a <em>31.4 Tbps DDoS attack</em>, it directs the focus on the bandwidth. But for engineers <em>packet rate (packets per second or PPS)</em> is often the more important number.</p><p>Routers, firewalls, and intrusion prevention systems process <em>one packet at a time</em>. Every packet requires parsing headers, validating checksums, making routing decisions, applying firewall rules, and often tracking connection state. If each operation takes only a few microseconds, the processing cost adds up when millions of packets arrive every second.</p><p>A 31.4 Tbps attack composed of small packets can generate <em>hundreds of millions of packets per second</em>. At that scale, the network link may have the capacity, but the CPUs protecting the infrastructure are overloaded before the bandwidth limit is reached.</p><p>This is why modern DDoS mitigation focuses on absorbing bandwidth and on <em>processing packets as efficiently as possible</em>. Technologies such as eBPF, XDP, hardware packet filtering, and SmartNICs work to drop malicious packets as early as possible, reducing the amount of work performed on every incoming packet.</p><p>In other words, <em>bandwidth gives you how much data is arriving, but packet rate decides how hard your infrastructure has to work.</em></p><p><strong>Attack Composition: Which Types Are Winning?</strong></p><p>The breakdown of real-world DDoS attacks by type. All attacks are not created equal, and understanding the mix reveals what defenders must prioritize:</p><figure><img alt="Attack composition" src="https://cdn-images-1.medium.com/max/902/1*3__Z1zLhRIk8RjhInjUOiQ.png" /></figure><p><strong>Key Insights</strong></p><p>1. <em>DNS Flood dominates </em>(33%)<br> — Why: Massive amplification factor (1 query → 50–100x response)<br> — Source: Open recursive resolvers worldwide (~2M still exposed in 2025)<br> — Impact: Can reach 10+ Tbps from relatively few botnet nodes<br> — Mitigation challenge: Requires upstream ISP coordination</p><p>2. <em>TCP SYN Flood is the second-largest threat</em> (27%)<br> — Why: Low-cost to generate, hard to rate-limit without breaking legitimate SYN/ACK<br> — Modern botnet twist: Randomized source IPs defeat simple IP-blocking<br> — Impact: The 31.4 Tbps attack likely included a heavy SYN component<br> — Trending up: Botnets are specializing in SYN generation</p><p>3. <em>UDP Flood accounts for 13%</em><br> — Why: Cheap to generate, can target any UDP service<br> — Sources: NTP reflection, SSDP (UPnP), DNS amplification<br> — Impact: Often layered with SYN attacks for diversified assault<br> — New wrinkle: Attackers now mix protocol types to evade single-protocol rate-limiters</p><p>4. <em>TCP RST and SSDP are niche but tactical</em><br> — TCP RST: Used to disrupt stateful connections after SYN flood opens gaps<br> — SSDP: Declining as UPnP devices are deprecated, but still effective on LAN networks<br> — Both serve specific roles in multi-stage attacks</p><p>5. <em>”Other” attacks (19%) are growing</em><br> — Fragmentation attacks (IP reassembly DoS)<br> — Slowloris (slow-rate HTTP floods)<br> — GRE/IP tunneling variants (harder to classify)<br> — Protocol-specific exploits (HTTP/2 reset floods, QUIC amplification)</p><p><strong>Multi-Vector Attacks: More Than Just a Flood</strong></p><p>Modern DDoS attacks are rarely a single stream of malicious traffic. Instead, attackers combine multiple techniques into a joint campaign, making mitigation significantly more difficult.</p><p>For example, an attack can start with a massive <em>TCP SYN flood</em> to exhaust connection tables. Followed by a <em>DNS amplification attack</em> which consumes upstream bandwidth, while an <em>HTTP flood</em> hits the application layer.</p><p>Some campaigns may even add slow-rate login attempts using stolen credentials, hoping that application-level attacks slip through unnoticed when defenders are focused only on the network flood.</p><p>Each attack vector targets a different layer of the infrastructure:</p><p>* DNS floods overwhelm network capacity.<br>* SYN floods exhaust firewall and server connection state.<br>* UDP floods consume bandwidth and CPU resources.<br>* HTTP floods target web servers and APIs.<br>* Credential stuffing attacks abuse authentication systems.</p><p>This layered approach forces engineers to respond on multiple fronts simultaneously. Blocking one protocol rarely stops the attack because the remaining vectors continue to increase load.</p><p>That is why modern protection relies on <em>layered defenses</em> rather than a single appliance or filtering rule: Network filtering, application-layer protection, bot detection, rate limiting, and continuous monitoring all working together to manage today’s increasingly sophisticated attacks.</p><p><strong>Botnets: The Infrastructure of Scale</strong></p><p>Attacks are orchestrated by a <em>botnet</em> — a network of compromised devices, each contributing a trickle of traffic that combines into a tsunami.</p><p><em>Botnet Evolution in 2025</em></p><ul><li>Kimwolf (Aisuru successor):<br>- Estimated size: 100,000–500,000 compromised nodes<br>- Target devices: Unpatched machines, IoT routers, smart home devices<br>- Command &amp; control: 550+ C2 nodes identified by Cloudflare in early 2026<br>- Sophistication: Automated exploitation of public CVEs + default credentials<br>- Cost to attacker: $10–100/month for C2 rental on underground markets</li><li>Other active botnets in 2025:<br>- Mirai variants (still alive, despite being “old”)<br>- Meris (specializes in HTTP floods)<br>- Gafgyt (targets home routers)<br>- Tsunami/Kaiten (Linux-focused, decades old but still effective)</li></ul><p><em>Why Botnets Still Work</em></p><ul><li>Weak security at IoT/edge<br> — Most IoT devices ship with default credentials (admin/admin, root/12345)<br> — Firmware updates are rare; many devices receive zero security patches<br> — Manufacturers prioritize cost over security</li><li>Massive attack surface<br> — Shodan, Censys, Fofa: Services that catalog exposed devices globally<br> — Attackers scan using these databases + automated exploitation<br> — One person can compromise 10,000 devices in a day</li><li>Legal gray area<br> — Botnet C2 services are available on underground forums<br> — Cost: $0.001–0.01 per compromised node per attack<br> — Law enforcement struggles with cross-border prosecution</li><li>Automation<br> — Attackers no longer need to write malware<br> — They only have buy access to botnets, specify targets and duration<br> — ROI is high: disrupt a competitor or extort a business for $100k with $500 in botnet rental</li></ul><p><strong>Beyond Volumetric: The Shift to “Logging In”</strong></p><p>While DDoS attacks grab headlines, the report reveals a more <em>insidious trend</em>: attacks are shifting from “breaking in” (exploiting vulnerabilities) to ”logging in” (using stolen credentials).</p><p><em>The Credential Compromise Crisis</em></p><p>- 63% of login attempts use compromised credentials (previously exposed in data breaches)<br>- 94% of all login attempts originate from bots (credential stuffing automation)<br>- Implication: Traditional rate-limiting and IP-blocking are ineffective against distributed, slow-rate attacks</p><p><em>Why This Matters for Defense</em></p><p>This shift means:</p><ul><li>DDoS + Credential Attacks are now coordinated<br> — Attackers launch a DDoS to distract security teams<br> — Simultaneously, they spray compromised credentials at login endpoints<br> — Security team is busy fighting the flood, missing the breach</li><li>Application-layer defenses become critical<br> — Network-level DDoS mitigation (rate-limiting, IP blocking) can’t see credential stuffing<br> — MFA, behavioral analytics, and SIEM become first-line defenses<br> — Traditional firewalls are blind to this attack class</li><li>Attack duration is changing<br> — Short, intense DDoS (0–30 minutes) designed to distract, not destroy<br> — Concurrent slow-rate login floods (hours/days) designed to find valid credentials<br> — Engineers must handle both simultaneously</li></ul><p><strong>The Economics of DDoS in 2025</strong></p><p><em>Attacker Cost vs. Defender Cost</em></p><figure><img alt="Attacker Cost vs Defender Cost" src="https://cdn-images-1.medium.com/max/1014/1*pDbOLxQcR-jQxvbPq93HwA.png" /></figure><p><em>The asymmetry is brutal</em>: Attackers spend thousands to cause millions in damages. Defenders must spend millions to prevent it.</p><p><strong>Why Traditional DDoS Defenses Are Failing</strong></p><ul><li><em>ISP/Upstream Defenses Are Insufficient</em></li></ul><p>ISPs typically offer basic DDoS mitigation:<br>- Null-routing (drop everything to the target)<br>- Rate-limiting at border routers<br>- GRE tunneling to scrubbing centers</p><p><em>Problem</em>: These are reactive, network-wide measures. They don’t protect <em>your</em> specific service. A 31.4 Tbps attack will saturate even well-provisioned ISP uplinks.</p><ul><li><em>Black-Box Commercial Solutions Hide the Defense</em></li></ul><p>Commercial solutionsuse proprietary ML models and undisclosed rate-limits. Organizations can’t:<br>- Understand why traffic was dropped<br>- Adjust thresholds for their specific workload<br>- Predict how new attack types will be handled<br>- Audit the effectiveness of defenses</p><ul><li><em>Legacy On-Premise Firewalls Are Too Slow</em></li></ul><p>Hardware firewalls use software packet inspection. At 31.4 Tbps:<br>- Each packet takes microseconds to evaluate<br>- 100 Gbps with normal 1,500-byte packets = 8.3 M packets/sec<br>- Packet-processing requirements can be much higher than the 8.3 Mpps figure if packets are small<br>- <em>Result</em>: Dropped packets, saturated CPU, failed defenses</p><ul><li><em>Rate-Limiting Alone Is Not Enough</em></li></ul><p>Simple per-IP rate-limits are evaded by:<br>- Randomized source IPs (spoofed, with ISP routing allowing it)<br>- Distributed botnet nodes (each sends slow-rate traffic individually, combining to a flood)<br>- Protocol mixing (SYN + UDP + DNS in a single attack)</p><p><strong>Defense Strategies: A Practical Framework</strong></p><p>Based on the various findings, effective DDoS defense requires a multi-layered approach:</p><ul><li><em>Layer 1: ISP / Upstream<br></em>- Work with ISP to implement RPKI/BGP Flowspec for source-spoofing prevention<br>- Negotiate DDoS traffic scrubbing at ISP edge (GRE tunnel to cleaning center)<br>- Monitor ISP’s abuse notification system for attack intelligence</li><li><em>Layer 2: Network (Layer 3–4)<br></em>- Deploy rate-limiting at your network edge (per-protocol, per-IP)<br>- Implement ingress filtering (drop spoofed packets)<br>- Monitor and tune fragmentation/reassembly policies<br>- Use DNS-specific tools (rate-limiting recursive resolvers, DNSSEC validation)</li><li><em>Layer 3: Application (Layer 7)<br></em>- Deploy WAF (Web Application Firewall) to drop malicious HTTP/HTTPS traffic<br>- Implement bot detection (JavaScript challenges, CAPTCHA, behavioral analysis)<br>- Rate-limit login endpoints (MFA, account lockout on failed attempts)<br>- Monitor for credential stuffing patterns (same password, different IPs)</li><li><em>Layer 4: Intelligence &amp; Response<br></em>- Subscribe to threat intelligence feeds (identify attacking botnets, C2 nodes)<br>- Integrate TI with firewall/WAF rules (auto-block known bad actors)<br>- Monitor dark web for mentions of your organization<br>- Participate in DDoS-sharing communities (Shadowserver, AbuseIPDB)</li><li><em>Layer 5: Detection &amp; Response<br></em>- Deploy SIEM to correlate DDoS events with other security signals<br>- Set up automated alerts for attack thresholds<br>- Maintain an incident response playbook (who to contact, what to do first)<br>- Practice DDoS response drills quarterly</li></ul><p><strong>What’s Coming: DDoS in 2026 and Beyond</strong></p><p>If 2025 saw 31.4 Tbps, what should we expect in 2026?</p><p><em>Projected Trends</em></p><ul><li>50+ Tbps attacks likely by 2027<br> — Botnet sizes are growing (more IoT, more default credentials)<br> — Attacker sophistication is increasing (protocol mixing, multi-stage attacks)<br> — Business ROI remains high (extortion, competitive disruption)</li><li>Credential compromise will accelerate<br> — More breaches = more leaked credentials<br> — Automation will improve (AI-driven credential testing)<br> — MFA fatigue attacks will increase</li><li>New attack vectors will emerge<br> — IPv6-based attacks (less-defended than IPv4)<br> — QUIC protocol amplification (HTTP/3 adoption)<br> — Blockchain/Web3 DDoS (attacking decentralized infrastructure)<br> — AI-generated evasion techniques (adaptive attacks that outrun rules)</li></ul><p><strong>Conclusion: The DDoS Reality Check</strong></p><p>The Threat Report isn’t a prediction — it’s a snapshot of what’s happening now.</p><ul><li>31.4 Tbps isn’t the ceiling; it’s the baseline.</li><li>Botnets aren’t going away; they’re being professionalized.</li><li>Attackers are diversifying: DDoS + credential compromise + persistence.</li><li>Traditional defenses (ISP rate-limiting, commodity firewalls) are insufficient.</li></ul><p><em>Organizations face a choice:</em></p><p>1. Accept the risk: Invest in DDoS insurance, incident response, and hope you’re not a target.</p><p>2. Invest in defense: Deploy layered DDoS mitigation (ISP + network + application layer), integrate threat intelligence, and practice incident response.</p><p>The 31.4 Tbps attack happened. It won’t be the last. The time to prepare is now.</p><p><strong>Resources &amp; Further Reading</strong></p><p><a href="https://blog.cloudflare.com/2026-threat-report/">Cloudflare 2026 Threat Report<br></a> <a href="https://www.securityweek.com/aisuru-and-kimwolf-ddos-botnets-disrupted-in-international-operation/">Kimwolf</a><br><a href="http://shadowserver.org/">Shadowserver Foundation<br></a><a href="http://abuseipdb.com/">AbuseIPDB</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cf21b6302c5b" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>