Skip to content
Memory corruption Write-up Advanced

No Login, Root Shellcode: Citrix NetScaler CVE-2026–88772 Is a

A buffer overflow in Citrix NetScaler's DTLS handshake reassembly allows an unauthenticated attacker to execute arbitrary code with root privileges. The flaw arises from a parsing inconsistency where the fragment length is trusted while the total length is used for reassembly, leading to a heap overflow.

Samadhan shimple Follow

Published on radiohackers.com

Cybersecurity

Samadhan shimple, on radiohackers.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 6 min read.

Context

Citrix NetScaler ADC and NetScaler Gateway are the appliances many organisations put in front of remote access and application delivery. The component at the centre of this story is the NetScaler Packet Processing Engine (NSPPE), the part of the appliance that handles network traffic, including DTLS handshake processing on VPN virtual servers.

DTLS is the datagram counterpart of TLS. Like TLS, it splits handshake messages into fragments, and each fragment carries two length fields:

  • fragment_length: the length of the current fragment
  • length: the total length of the complete handshake message

Reassembly code is supposed to use those two fields consistently. CVE-2026-88772 is the case where it did not.

Citrix NetScaler CVE-2026–88772 From the original on radiohackers.com

The vulnerability is a memory overflow in that DTLS handshake reassembly path, rated CVSS 9.5 (Critical), and it gives a pre-authentication path to shellcode execution with root privileges. It was exploited in the wild as a zero-day alongside CVE-2026-88771, and CISA added both to its Known Exploited Vulnerabilities catalogue. CISA describes the flaw as an "improper restriction of operations within the bounds of a memory buffer vulnerability that could allow for remote code execution or denial-of-service".

At a glance:

Field Value
CVE ID CVE-2026-88772
CVSS score 9.5 (Critical)
Affected products Citrix NetScaler ADC, NetScaler Gateway
Root cause Buffer overflow in DTLS handling (NSPPE)
Impact Pre-auth RCE or DoS
Exploitation status Actively exploited in the wild
Patch CTX697096 (14.1-73.37 / 13.1-64.23+)

Setup

The report describes no accounts, roles or tooling on the attacker side beyond the ability to send DTLS traffic. The precondition is network access to the DTLS service, typically UDP port 443, with no authentication required. DTLS is enabled by default on VPN virtual servers, so any deployment that has not explicitly disabled it is exposed. The analysis of the exploitation path is attributed to watchTowr, with Sina Kheirkhah quoted on the data discrepancy.

Finding it

The root cause is a parsing inconsistency in how NetScaler processes DTLS handshake fragments. The appliance implicitly trusts the declared fragment_length value while simultaneously using the length field for reassembly bookkeeping. Those two fields are meant to describe the same message, and an attacker can make them disagree.

According to watchTowr's analysis, an attacker can craft records where the fragment_length field claims 1 byte, while the header's length field declares the complete message is 120 bytes long. The reassembly code believes each record contributes one byte towards a 120-byte message, but the amount of data actually retained per record is far larger. That gap between what the metadata claims and what the code stores is the whole bug.

Exploitation

Step 1: Fragment metadata manipulation

Each malicious DTLS record tells the reassembly code that it supplies only 1 byte of the 120-byte handshake message. However, NSPPE stores almost the entire record, approximately 1,459 bytes per packet, in a NetScaler Buffer (NSB). The declared fragment size and the stored size are therefore unrelated, and the reassembly logic keeps counting down from 120 based on the declared value.

Step 2: Scratch buffer overflow

These NSBs are stitched together into a single scratch buffer of only 35,840 bytes. Critically, the vulnerable version does not verify whether the next packet can fit into the scratch buffer before writing. The result is that data is written past the buffer's end, causing a heap-based buffer overflow.

Step 3: Massive data discrepancy

The arithmetic is damning:

  • Expected data: 120 bytes (based on reassembly metadata)
  • Actual data: ~174 KB (NSB chain content)

As Kheirkhah put it:

"The malicious records tell the reassembly code that each record supplies only one byte of a 120-byte handshake message. However, NSPPE keeps almost the whole record in an NSB. After 120 records, the handshake message is considered complete, but its NSB chain contains about 174 KB of data."

After 120 records are processed, the reassembly code declares the handshake complete, but the scratch buffer has been overwhelmed with nearly 1,500 times the expected data volume.

Step 4: Defeating NX protections

The overflow is not merely a denial-of-service primitive. watchTowr's analysis demonstrates a viable exploitation path to arbitrary shellcode execution with root-level privileges. Modern systems employ NX (No-Execute) protections that mark memory regions as either writable or executable, but not both. The exploit bypasses this by:

  1. Using the buffer overflow to gain control of the instruction pointer
  2. Leveraging a ROP (Return-Oriented Programming) chain
  3. Invoking the mprotect() system call to mark a memory region as both writable and executable

The mprotect() system call allows the attacker to change memory page permissions, effectively converting a writable buffer into an executable one. Once this is achieved, arbitrary shellcode can be injected and executed.

Step 5: Root-level impact

Because NSPPE runs with elevated privileges on the NetScaler appliance, successful exploitation grants root-level code execution. This level of access allows an attacker to:

  • Completely compromise the NetScaler appliance
  • Intercept or manipulate all traffic passing through it
  • Pivot into internal networks
  • Establish persistent backdoors

Root cause

The mistake is a parser differential: the code trusts one length field (fragment_length) when deciding how much of the message has been received, while using another (length) for reassembly bookkeeping, and it stores the actual record contents in an NSB regardless of what the metadata claims. The scratch buffer that the NSBs are stitched into is fixed at 35,840 bytes, and the vulnerable version does not check whether the next packet fits before writing. The declared 120-byte message therefore completes after 120 records while roughly 174 KB of NSB content has been written into a much smaller buffer.

NX does not stop this on its own, because the overflow first gives control of the instruction pointer and a ROP chain then calls mprotect() to make a region writable and executable before shellcode runs.

Impact

Successful exploitation gives root-level code execution on the appliance, which means full compromise of the NetScaler, interception or manipulation of all traffic passing through it, pivoting into internal networks and persistent backdoors. The flaw also provides a denial-of-service primitive. It requires only network access to the DTLS service, typically UDP port 443, with no authentication, and DTLS is enabled by default on VPN virtual servers, so deployments that have not explicitly disabled it are exposed. Organisations using NetScaler Gateway for remote access are particularly exposed because those deployments almost universally have DTLS enabled.

CVE-2026-88772 was exploited as a zero-day before patches were available. CISA confirmed that threat actors are actively exploiting both CVE-2026-88771 and CVE-2026-88772 globally, and the two have been abused in tandem in real-world attacks, with CVE-2026-88771 providing an initial foothold that is escalated via the DTLS overflow.

Fix

Citrix released patches in NetScaler ADC/Gateway 14.1-73.37 and 13.1-64.23 (and later), along with FIPS and NDcPP variants, under advisory CTX697096. Patching is urgent, but organisations should preserve forensic evidence first if compromise is suspected.

Variants to test

  • A positive result is that the reassembly code accepts the records and completes the message after 120 of them rather than rejecting the inconsistency.
  • A positive result is completion at a record count derived from the declared length while the stored NSB chain is far larger.
  • A positive result is any path where a declared fragment size is used for bookkeeping while the full record is retained.
  • A positive result is a DTLS listener reachable on UDP port 443 without authentication, which is the exposure condition for this bug.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 14 min read.

What happened, in plain words

Citrix makes two products called NetScaler ADC and NetScaler Gateway. Many organisations put these appliances in front of their remote access and their applications, so staff and customers can reach internal systems from outside. Think of them as the reception desk of a building: everyone who wants to get in passes the desk first, and the desk decides who is allowed through and where they go.

Inside that appliance there is a piece of software called the NetScaler Packet Processing Engine, or NSPPE. It is the part that handles network traffic, including a protocol called DTLS on VPN virtual servers. A VPN virtual server is a configured entry point on the appliance that remote users connect to.

A serious memory overflow bug was found in that DTLS handling. It was given the identifier CVE-2026-88772 and a severity score of 9.5 out of 10, which is rated Critical. The bug lets an attacker who has not logged in at all reach a point where they can run their own code on the appliance with root privileges, meaning the highest level of control on the machine. It was used in real attacks before a patch existed, together with a second bug, CVE-2026-88771. The US agency CISA added both to its Known Exploited Vulnerabilities catalogue, a public list of flaws known to be used in attacks.

CISA describes the flaw as an "improper restriction of operations within the bounds of a memory buffer vulnerability that could allow for remote code execution or denial-of-service". In plain words: the software writes data further than the space it reserved for it, and that can let an outsider run code or crash the service.

Citrix NetScaler CVE-2026–88772 From the original on radiohackers.com

The image is the article's title card for Citrix NetScaler CVE-2026-88772.

Here is the summary table from the report:

Field Value
CVE ID CVE-2026-88772
CVSS score 9.5 (Critical)
Affected products Citrix NetScaler ADC, NetScaler Gateway
Root cause Buffer overflow in DTLS handling (NSPPE)
Impact Pre-auth RCE or DoS
Exploitation status Actively exploited in the wild
Patch CTX697096 (14.1-73.37 / 13.1-64.23+)

A few of those terms need unpacking. A CVE ID is a public catalogue number for a known security flaw, so people can talk about the same bug unambiguously. CVSS is a scoring system from 0 to 10 that tries to express how bad a flaw is. "Pre-auth" means the attacker does not need to log in first. RCE stands for remote code execution, meaning an attacker somewhere on the network can make the machine run code of their choosing. DoS stands for denial of service, meaning the attacker can make the service stop working. "Exploited in the wild" means real attackers have used it, not just researchers in a lab. The patch line names the Citrix advisory, CTX697096, and the software versions that contain the fix.

Setup

The report describes no accounts, roles or tools on the attacker side beyond the ability to send DTLS traffic. That is the whole precondition: network access to the DTLS service, typically UDP port 443, with no authentication required.

Two ideas there. UDP is one of the basic ways computers send data over a network; unlike its sibling TCP, it does not first set up a confirmed connection, it just fires packets. A port number is like a door number on a building: port 443 is the door normally used for encrypted web traffic, and here the appliance also listens on it for DTLS. DTLS is enabled by default on VPN virtual servers, so any deployment that has not explicitly turned it off is exposed.

The analysis of the exploitation path is attributed to watchTowr, with Sina Kheirkhah quoted on the data discrepancy.

Finding it

What DTLS is, and why it has two length fields

DTLS is the datagram counterpart of TLS. TLS is the protocol that puts the padlock in your browser and encrypts traffic between you and a website. DTLS does the same job for traffic sent over UDP, where messages can arrive out of order or get lost.

Like TLS, DTLS splits handshake messages into fragments. The handshake is the opening conversation where the two sides agree how to talk securely. Because a message can be large, it is cut into pieces, and each piece carries two length fields:

  • fragment_length: the length of the current fragment
  • length: the total length of the complete handshake message

Think of posting a long letter in several envelopes. On each envelope you write two things: how many pages are inside this envelope (fragment_length), and how many pages the whole letter has (length). The receiver uses both to put the letter back together.

Reassembly code is supposed to use those two fields consistently. CVE-2026-88772 is the case where it did not.

The inconsistency

The root cause is a parsing inconsistency in how NetScaler processes DTLS handshake fragments. Parsing means reading incoming data and working out what it means. The appliance implicitly trusts the declared fragment_length value while simultaneously using the length field for reassembly bookkeeping. Those two fields are meant to describe the same message, and an attacker can make them disagree.

According to watchTowr's analysis, an attacker can craft records where the fragment_length field claims 1 byte, while the header's length field declares the complete message is 120 bytes long. A byte is a single character's worth of data, the smallest unit we usually count. So the envelope says "one page inside" while the cover note says "the letter is 120 pages".

The reassembly code believes each record contributes one byte towards a 120-byte message, but the amount of data actually retained per record is far larger. That gap between what the metadata claims and what the code stores is the whole bug. Metadata here means the descriptive fields, the labels on the envelope, as opposed to the actual contents.

Exploitation

Step 1: Fragment metadata manipulation

Each malicious DTLS record tells the reassembly code that it supplies only 1 byte of the 120-byte handshake message. However, NSPPE stores almost the entire record, approximately 1,459 bytes per packet, in a NetScaler Buffer (NSB).

A buffer is a reserved chunk of memory used to hold data temporarily, like a tray you put papers on while you sort them. An NSB is NetScaler's own name for such a buffer. The declared fragment size and the stored size are therefore unrelated, and the reassembly logic keeps counting down from 120 based on the declared value.

Why does this matter? Because the code is keeping two separate sets of books. One book says "I have received 1 byte, 119 to go". The other book, the memory, is quietly filling up with about 1,459 bytes per packet. The attacker controls the difference between the two.

Step 2: Scratch buffer overflow

These NSBs are stitched together into a single scratch buffer of only 35,840 bytes. A scratch buffer is a working area where pieces are assembled before the finished message is handed on, like a table where you lay out the pages of a letter in order.

Critically, the vulnerable version does not verify whether the next packet can fit into the scratch buffer before writing. The result is that data is written past the buffer's end, causing a heap-based buffer overflow.

A buffer overflow is exactly what it sounds like: you keep pouring into a container after it is full, and the liquid runs over the sides onto whatever is next to it. In memory, whatever sits next to the buffer gets overwritten. The heap is the general-purpose pool of memory a program uses for data it creates while running, as opposed to the more rigid stack; a heap-based overflow means the overwritten memory lives in that pool.

Step 3: Massive data discrepancy

The arithmetic is damning:

  • Expected data: 120 bytes (based on reassembly metadata)
  • Actual data: ~174 KB (NSB chain content)

KB means kilobytes, roughly a thousand bytes, so 174 KB is about 174,000 bytes. The code expected 120 and got roughly 1,450 times more.

As Kheirkhah put it:

"The malicious records tell the reassembly code that each record supplies only one byte of a 120-byte handshake message. However, NSPPE keeps almost the whole record in an NSB. After 120 records, the handshake message is considered complete, but its NSB chain contains about 174 KB of data."

After 120 records are processed, the reassembly code declares the handshake complete, but the scratch buffer has been overwhelmed with nearly 1,500 times the expected data volume. The attacker has, in effect, written a large amount of their own data into memory next to the buffer, and the program has no idea it happened.

Step 4: Defeating NX protections

Why would an attacker want to overflow a buffer at all? Because the memory just past the buffer often holds things the program relies on, including the instruction pointer: the marker that tells the processor which instruction to run next. If you can overwrite that marker, you can redirect the program to code you supplied.

The overflow is not merely a denial-of-service primitive. watchTowr's analysis demonstrates a viable exploitation path to arbitrary shellcode execution with root-level privileges. Shellcode is a small piece of machine code an attacker wants the victim machine to run.

Modern systems employ NX (No-Execute) protections that mark memory regions as either writable or executable, but not both. The idea is simple: if attackers can write data into a region, that region should not also be runnable as code, so their written data cannot become a program. It is like a rule that says paper trays may hold paper but may never be used as a printing press.

The exploit bypasses this by:

  1. Using the buffer overflow to gain control of the instruction pointer
  2. Leveraging a ROP (Return-Oriented Programming) chain
  3. Invoking the mprotect() system call to mark a memory region as both writable and executable

ROP deserves a plain explanation. The program already contains many small snippets of legitimate code, each ending in a return instruction, which means "go back to wherever I was called from". A ROP chain is a crafted list of return addresses that makes the processor hop from one existing snippet to the next, like a trail of stepping stones made of the program's own code. The attacker never has to inject new executable code; they just rearrange the order in which existing code runs.

The mprotect() system call allows the attacker to change memory page permissions, effectively converting a writable buffer into an executable one. A system call is a request from a program to the operating system to do something on its behalf, such as change memory settings. A memory page is a fixed-size block of memory that the operating system manages as a unit. Once the region is both writable and executable, arbitrary shellcode can be injected and executed.

Step 5: Root-level impact

Because NSPPE runs with elevated privileges on the NetScaler appliance, successful exploitation grants root-level code execution. Root is the all-powerful account on a Unix-like system; code running as root can do anything the machine can do.

This level of access allows an attacker to:

  • Completely compromise the NetScaler appliance
  • Intercept or manipulate all traffic passing through it
  • Pivot into internal networks
  • Establish persistent backdoors

Each of those deserves a moment. Compromising the appliance means the attacker owns the reception desk. Intercepting or manipulating traffic means reading or altering everything that passes through it, including logins and business data. Pivoting means using the compromised machine as a launchpad to reach other systems that were never directly reachable from outside. A persistent backdoor is a way back in that survives reboots and password changes.

Root cause

The mistake is a parser differential: the code trusts one length field (fragment_length) when deciding how much of the message has been received, while using another (length) for reassembly bookkeeping, and it stores the actual record contents in an NSB regardless of what the metadata claims. A parser differential is when two parts of a system read the same input differently, and an attacker exploits the gap between the two readings.

The scratch buffer that the NSBs are stitched into is fixed at 35,840 bytes, and the vulnerable version does not check whether the next packet fits before writing. The declared 120-byte message therefore completes after 120 records while roughly 174 KB of NSB content has been written into a much smaller buffer.

NX does not stop this on its own, because the overflow first gives control of the instruction pointer and a ROP chain then calls mprotect() to make a region writable and executable before shellcode runs.

Impact

Successful exploitation gives root-level code execution on the appliance, which means full compromise of the NetScaler, interception or manipulation of all traffic passing through it, pivoting into internal networks and persistent backdoors. The flaw also provides a denial-of-service primitive.

It requires only network access to the DTLS service, typically UDP port 443, with no authentication, and DTLS is enabled by default on VPN virtual servers, so deployments that have not explicitly disabled it are exposed. Organisations using NetScaler Gateway for remote access are particularly exposed because those deployments almost universally have DTLS enabled.

CVE-2026-88772 was exploited as a zero-day before patches were available. A zero-day is a flaw that attackers use before the vendor has a fix ready, so defenders have no patch to apply. CISA confirmed that threat actors are actively exploiting both CVE-2026-88771 and CVE-2026-88772 globally, and the two have been abused in tandem in real-world attacks, with CVE-2026-88771 providing an initial foothold that is escalated via the DTLS overflow. An initial foothold is the first small bit of access an attacker gets; escalation is turning that into more control.

Fix

Citrix released patches in NetScaler ADC/Gateway 14.1-73.37 and 13.1-64.23 (and later), along with FIPS and NDcPP variants, under advisory CTX697096. FIPS and NDcPP are certification profiles for government and regulated environments; the point is that patched builds exist for those variants too.

Patching is urgent, but organisations should preserve forensic evidence first if compromise is suspected. Forensic evidence means logs, memory captures and disk images that let investigators work out what happened; rebooting or wiping a machine to patch it can destroy that evidence.

Variants to test

Each one is a way of asking the same question: does the appliance believe the labels or the contents?

  • A positive result is that the reassembly code accepts the records and completes the message after 120 of them rather than rejecting the inconsistency.
  • A positive result is completion at a record count derived from the declared length while the stored NSB chain is far larger.
  • A positive result is any path where a declared fragment size is used for bookkeeping while the full record is retained.
  • A positive result is a DTLS listener reachable on UDP port 443 without authentication, which is the exposure condition for this bug.

Glossary

  • ADC: Application Delivery Controller, the Citrix product that sits in front of applications and manages traffic to them.
  • Buffer: A reserved area of memory used to hold data temporarily.
  • Buffer overflow: Writing more data into a buffer than it can hold, so the extra data overwrites neighbouring memory.
  • CISA: The US Cybersecurity and Infrastructure Security Agency, which publishes the Known Exploited Vulnerabilities catalogue.
  • Critical: The top severity rating in the CVSS scoring system.
  • CVE ID: A public catalogue number for a known security flaw.
  • CVSS: A scoring system from 0 to 10 expressing the severity of a flaw.
  • Denial of service (DoS): Making a service stop working for legitimate users.
  • DTLS: The datagram counterpart of TLS, providing encryption for traffic sent over UDP.
  • FIPS: A set of US government certification requirements for cryptographic software.
  • Fragment: One piece of a larger message that has been split up for transmission.
  • fragment_length: The field stating how long the current fragment is.
  • Handshake: The opening conversation in which two systems agree how to communicate securely.
  • Heap: The general-purpose pool of memory a program uses for data created while it runs.
  • Instruction pointer: The marker telling the processor which instruction to run next.
  • length: The field stating the total length of the complete handshake message.
  • Metadata: Descriptive fields about data, as opposed to the data's contents.
  • mprotect(): A system call that changes the permissions of a region of memory.
  • NDcPP: A certification profile for network devices used in regulated environments.
  • NetScaler Buffer (NSB): NetScaler's own structure for holding a chunk of received data.
  • NetScaler Gateway: The Citrix product used for remote access.
  • NSPPE: NetScaler Packet Processing Engine, the component that handles network traffic on the appliance.
  • NX (No-Execute): A protection that stops memory being both writable and executable at the same time.
  • Parser differential: A flaw where two parts of a system interpret the same input differently, and the gap is exploitable.
  • Parsing: Reading incoming data and working out what it means.
  • Port: A numbered door on a machine that a particular service listens on.
  • Pre-auth: Reachable without logging in first.
  • Remote code execution (RCE): Making a machine run code of the attacker's choosing over the network.
  • ROP (Return-Oriented Programming): Chaining together small existing code snippets in a program to make it do something new.
  • Root: The all-powerful account on a Unix-like system.
  • Scratch buffer: A working area of memory where pieces are assembled before use.
  • Shellcode: A small piece of machine code an attacker wants the victim machine to run.
  • System call: A request from a program to the operating system to perform a privileged action.
  • TLS: The protocol that encrypts traffic between a browser and a website.
  • UDP: A simple way of sending data over a network without first setting up a confirmed connection.
  • VPN virtual server: A configured entry point on the appliance that remote users connect to.
  • Zero-day: A flaw exploited by attackers before the vendor has a fix available.

More by Samadhan shimple

View all

7 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.