It's CitrixBleed, again — the same wound in the same appliance, two years later
CVE-2025-5777 is an out-of-bounds read in NetScaler ADC and NetScaler Gateway when configured as a Gateway (VPN vserver, ICA Proxy, CVPN, RDP Proxy) or as an AAA virtual server. An unauthenticated attacker sends a crafted POST to the login endpoint (/p/u/doAuthentication.do) without a login= parameter body, and the appliance echoes back ~127 bytes of uninitialized stack memory in the <InitialValue> XML field. Repeat the request a few thousand times and you harvest session cookies, credentials, and MFA tokens straight out of TLS memory. Affected: NetScaler ADC/Gateway 14.1 before 14.1-43.56, 13.1 before 13.1-58.32, and all 13.1-FIPS/NDcPP before 13.1-37.235-FIPS. 12.1 and 13.0 are EOL and will not be patched — those appliances are permanently broken.
The vendor's HIGH / 7.5 rating is materially wrong and Citrix knows it. The CVSS vector claims *Confidentiality: High, Integrity: None, Availability: None* — but a leaked authenticated session token collapses directly to Integrity:High and Availability:High because the attacker inherits *whatever the hijacked user could do*, including admin. This is the textbook replay of CVE-2023-4966 (CitrixBleed 1) which enabled the LockBit/Boeing/Comcast/ICBC intrusions. CISA added it to KEV on 2025-07-10; watchTowr, Horizon3, and Assetnote published working PoCs; Shadowserver logged mass exploitation from mid-June 2025. Treat vendor severity as marketing, not signal.
5 steps from start to impact.
Identify an exposed NetScaler Gateway
/vpn/index.html, /logon/LogonPoint/, or the NSC_ cookie namespace. Shodan and Censys both dork this trivially; roughly 56,000–60,000 appliances are reachable from the public internet.- Appliance is internet-exposed
- Gateway or AAA vserver role is enabled (not just LB/CS)
- Pure load-balancer configurations without a Gateway/AAA vserver are NOT vulnerable
- Some tenants front NetScaler behind a WAF/CDN with URI filtering
http.favicon.hash:-1292923998, Censys services.tls.certificates.leaf_data.subject.common_name:*netscaler*, GreyNoise tag Citrix NetScaler Memory Disclosure AttemptSend malformed doAuthentication POST
POST /p/u/doAuthentication.do with Content-Type: application/x-www-form-urlencoded and a body containing login without a value or without the = sign. The server parses the missing field, allocates the response buffer, and echoes uninitialized stack memory inside the <InitialValue>...</InitialValue> tag of the XML SAML/nFactor response. Public PoC: watchTowr/CitrixBleed-2, Horizon3 Attack Team, and Assetnote blog + Nuclei template.- Reachable HTTPS to the Gateway vserver
- None — no auth, no user interaction, no rate limit by default
citrix-netscaler-memory-leak.yamlLoop to harvest secrets
NSC_AAAC, NSC_TMAS, JSON web tokens, base64-encoded credentials, and cleartext passwords submitted by concurrent legitimate users. Horizon3's PoC pulls a usable session token in under 15 minutes against a moderately-trafficked box.- Live user traffic on the appliance (more users = faster loot)
- No rate limiting on the login endpoint
- Idle appliances leak slower — stack is stale
- Some deployments have AppFW rate-limit policies
doAuthentication.do from a single source without corresponding successful auth is a strong indicatorReplay session cookie, bypass MFA entirely
NSC_AAAC cookie into Burp/Chrome and lands directly inside the authenticated Gateway session — no username, no password, no MFA prompt. If the hijacked session belongs to an admin, they own the appliance; if it belongs to a VPN user, they inherit that user's network position. Tool: CitrixBleed-2 exploit (watchTowr), projectdiscovery/nuclei-templates.- A valid session existed in the leaked memory window
- Session hasn't idled out
- Short session timeouts (< 15 min) reduce yield
- Source-IP-bound sessions (rare) break replay
Pivot to internal network
- ICA Proxy / VPN full-tunnel or split-tunnel exposes internal resources
- Well-segmented tenants restrict Gateway users to a jump host — most do not
The supporting signals.
| In-the-wild | Active mass exploitation since mid-June 2025 per Shadowserver and ReliaQuest; multiple ransomware affiliates observed pivoting through hijacked sessions |
|---|---|
| Public PoC | watchTowr, Horizon3 Attack Team writeup, Assetnote analysis, Nuclei template merged upstream |
| EPSS | 0.99897 (top 0.1% of all CVEs) — model is screaming |
| CISA KEV | Listed 2025-07-10 with a 21-day federal remediation deadline |
| CVSS vector | AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N — network, no auth, no UI. I:N and A:N are wrong; session hijack drives both to High |
| Affected versions | NetScaler ADC/Gateway 14.1 < 14.1-43.56, 13.1 < 13.1-58.32, 13.1-FIPS/NDcPP < 13.1-37.235; 12.1 and 13.0 are EOL — no patch coming |
| Fixed versions | 14.1-43.56, 13.1-58.32, 13.1-37.235-FIPS/NDcPP. Kill all sessions post-upgrade: kill icaconnection -all and kill pcoipConnection -all and kill aaa session -all |
| Exposure | ~56,000–60,000 internet-facing NetScaler Gateways per Shodan; ~1,200 still unpatched in Fortune 500 ASNs per Censys as of late June 2025 |
| Disclosed | 2025-06-17 by Citrix advisory CTX693420, coordinated with Positive Technologies |
| Reporter | Positive Technologies (initial disclosure); reverse-engineered patch diff by watchTowr Labs and Horizon3 |
noisgate verdict.
Unauthenticated pre-auth memory disclosure on an internet-facing identity/edge appliance with confirmed mass exploitation and KEV listing is the single most decisive factor — this is a canonical high-value-role component (network edge + identity gateway) and the leaked bytes are session tokens that collapse directly into MFA bypass. The vendor's I:N / A:N framing understates impact because a hijacked admin session yields full appliance takeover, which is why the reassessed score sits at 9.8 rather than 7.5.
Why this verdict
- KEV + active exploitation: listed 2025-07-10, Shadowserver telemetry confirms mass scanning and successful hits from mid-June onward
- Role multiplier: NetScaler Gateway is a canonical high-value-role component — it IS the identity edge. Chain succeeds → attacker inherits any user's authenticated session including admin → fleet floor is CRITICAL
- No friction on the reach step: unauthenticated, single POST, no UI, no rate limit by default; ~60k appliances directly exposed
- Vendor CVSS is under-scored: I:N/A:N ignores that the leaked data IS the session token; realistic vector is
C:H/I:H/A:H→ 9.8 - Session-token replay defeats MFA: the token was minted post-MFA, so hardware keys, OTP, and push MFA provide zero defense against replay
- Historical precedent: CitrixBleed 1 (CVE-2023-4966) drove LockBit's biggest 2023 campaign — same class, same appliance, same outcome
Why not higher?
9.8 is effectively the ceiling for a remote unauthenticated compromise of a widely-deployed edge appliance; a 10.0 would require guaranteed pre-auth RCE with no preconditions, and this is a memory-disclosure primitive that requires live sessions to be present in the target's stack. Absent that live traffic, an idle appliance yields little.
Why not lower?
Downgrading to HIGH would require either narrow exposure (there are ~60k reachable devices — the opposite of narrow), the absence of a public PoC (there are three), or no in-the-wild use (KEV-listed with active campaigns). None of those conditions hold. The vendor's 7.5 is a scoring artifact, not a real-world risk statement.
What to do — in priority order.
- Patch to 14.1-43.56 / 13.1-58.32 / 13.1-37.235-FIPS immediately — This is the ONLY durable fix. Per noisgate mitigation SLA for CRITICAL + active KEV exploitation: patch within hours, not days. Schedule the maintenance window today.
- Kill all active sessions post-upgrade — Patching alone does not evict attackers who already stole tokens. On each appliance run
kill aaa session -all,kill icaconnection -all,kill pcoipConnection -all, and rotate all admin passwords and any credentials that transited the box. Do this within the same maintenance window. - If you cannot patch in <72h, disable the Gateway/AAA vservers —
disable vserver <name>on any VPN, ICA Proxy, CVPN, RDP Proxy, or AAA vserver removes the attack surface entirely until the patch is applied. Yes, this breaks remote access; that is the correct trade under CRITICAL SLA. - Deploy the Citrix responder policy from CTX693420 — Vendor-published responder policy blocks the malformed
doAuthentication.dorequest pattern. Interim only — treat as a speed bump while you schedule the reboot, not a substitute for the patch. - Hunt for indicators back to 2025-06-01 — Look for high-volume
doAuthentication.doPOSTs without matchingsaml/logincompletions, new admin accounts, config exports, and session cookies used from anomalous ASNs. Feed ns.log to your SIEM if you have not already. - Rotate LDAP bind, RADIUS shared secrets, and any stored service credentials on the appliance — If an admin session was hijacked,
show runexposes these secrets. Rotate them on the assumption of compromise for any appliance internet-exposed in June 2025.
- MFA on the Gateway — the stolen token was minted AFTER MFA succeeded; replay bypasses it entirely
- IP allow-lists on the admin interface — the vulnerable endpoint is the user-facing
/p/u/doAuthentication.do, not/nsconfig - Short password rotation — the leak yields session tokens, not passwords; rotating passwords does not invalidate active NSC_AAAC cookies
- Web Application Firewall in default mode — signatures for this bug are recent (post-June 2025); confirm your WAF vendor shipped a rule and it is in *block* mode, not *log*
- Upgrading 12.1 or 13.0 — they are EOL, there is no patched build; migrate to 14.1 or decommission
Crowdsourced verification payload.
Run this from an auditor workstation with network reach to the appliance's Gateway vserver — not on the NetScaler itself. Invoke as ./check-citrixbleed2.sh https://gateway.example.com. Requires only curl and grep; no credentials. It sends the malformed doAuthentication POST and inspects the <InitialValue> field for leaked memory.
#!/usr/bin/env bash
# noisgate verifier for CVE-2025-5777 (CitrixBleed 2)
# Usage: ./check-citrixbleed2.sh https://gateway.example.com
# Exit: 0 PATCHED, 1 VULNERABLE, 2 UNKNOWN
set -u
TARGET="${1:-}"
if [[ -z "$TARGET" ]]; then
echo "Usage: $0 https://<netscaler-gateway>" >&2
exit 2
fi
UA="noisgate-verifier/1.0"
ENDPOINT="${TARGET%/}/p/u/doAuthentication.do"
# Malformed body: 'login' key without value triggers the OOB read
RESPONSE=$(curl -sk --max-time 15 \
-H "User-Agent: $UA" \
-H "Content-Type: application/x-www-form-urlencoded" \
-X POST --data "login" \
"$ENDPOINT" 2>/dev/null)
RC=$?
if [[ $RC -ne 0 ]] || [[ -z "$RESPONSE" ]]; then
echo "UNKNOWN: could not reach $ENDPOINT (curl rc=$RC)"
exit 2
fi
# Fingerprint 1: must look like a NetScaler nFactor response
if ! grep -qiE "(InitialValue|NSC_|<Response|SAMLResponse)" <<< "$RESPONSE"; then
echo "UNKNOWN: response does not look like a NetScaler Gateway (is a Gateway/AAA vserver bound here?)"
exit 2
fi
# Fingerprint 2: on VULNERABLE builds InitialValue is populated with junk
# even though we never supplied a login value. Extract it.
INITIAL=$(grep -oP '(?<=<InitialValue>).*?(?=</InitialValue>)' <<< "$RESPONSE" | head -1)
if [[ -n "$INITIAL" ]] && [[ "${#INITIAL}" -gt 0 ]]; then
# Non-empty InitialValue on an unauth request = memory being echoed
echo "VULNERABLE: $ENDPOINT returned non-empty <InitialValue> to unauthenticated request"
echo "Leaked bytes (first 80): ${INITIAL:0:80}"
exit 1
fi
# On patched builds InitialValue is absent or empty
if grep -qE "<InitialValue></InitialValue>|<InitialValue/>" <<< "$RESPONSE" || ! grep -q "InitialValue" <<< "$RESPONSE"; then
echo "PATCHED: $ENDPOINT did not echo memory in <InitialValue>"
exit 0
fi
echo "UNKNOWN: indeterminate response, inspect manually"
exit 2
If you remember one thing.
disable vserver on every Gateway/AAA vserver until you can. The noisgate remediation SLA of ≤90 days does not apply here — active exploitation collapses it to *today*. Immediately after upgrade, run kill aaa session -all plus the ICA/PCoIP kill commands, rotate LDAP bind + RADIUS shared secrets + admin passwords, and hunt ns.log back to 2025-06-01 for high-volume doAuthentication.do POSTs and session cookies used from anomalous ASNs. Any 12.1 or 13.0 appliance is EOL and cannot be patched — decommission or migrate this week.Sources
What defenders are saying.
Crowdsourced verification outputs.
Results submitted by users who ran the verification payload against their environment.