CVE-2026-125350: A Chrome Renderer Crash From an XSLT Stylesheet
The CVE record for CVE-2026-125350 says the bug “allowed a remote attacker to execute arbitrary code inside the sandbox via a crafted HTML page”. Google’s advisory of 2026-11-09 adds that an exploit exists in the wild, and the CVE was added to CISA’s Known Exploited Vulnerabilities catalog on 2026-11-10.
I reproduced less than that, and this post says how much. An XML document with an XSLT stylesheet, served over HTTP, crashes the sandboxed renderer of stock Google Chrome 157.0.8103.38 on Linux, with no flag. The same page does nothing to 157.0.8103.50. On a sanitizer build one revision before the fix, the crash is a heap use after free in libxslt. I did not attempt code execution.
The trigger is not new. Its two shapes follow the two cases of the crash test that the fix commit added to Chromium. What I add is a lab of stock Chrome builds pinned by checksum, the raw output of every run, the sanitizer’s allocation stacks for both cases with the reason in libxslt’s code why each leaves a stale object behind, a check that does not trigger the bug, live captures, and tested Suricata and YARA rules. All of it is in the repository: al4n4n/achilles-heel/CVE-2026-125350.
The target: XSLT inside the renderer
Chrome runs XSLT with a bundled copy of libxslt, and it runs it inside the renderer process. The page in this post needs no script to reach that code: the browser loads an XML document, finds an xml-stylesheet processing instruction in it, fetches the stylesheet and applies it. The user does one thing, which is to open the URL.
The advisory names Google Chrome only and gives no figures on scale, so I give none. The CVSS 3.1 vector from CISA is AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H, 8.8 High.
A cache and a pointer that outlives it
The bug is in one function, xsltTestCompMatchDirect() in pattern.c. libxslt uses it as a shortcut for patterns with two predicates in a row, such as book[p][q]. It evaluates //book[p][q] once per document and caches the resulting node-set object in a slot of the transform context that belongs to the pattern, together with the document it was computed for.
On entry the function copies the cached pointer into a local variable. If the node it is asked about sits in another document, it evaluates the pattern again with xmlXPathEval(), frees the old object through that local variable and stores the new one.
The trouble is what the evaluation can do in between. A predicate that reads a global variable not yet computed makes libxslt evaluate the variable’s body on the spot. If that body runs an xsl:number whose count pattern uses the same slot, the function is entered a second time. The nested call frees the cached object and installs another.
Back in the outer call, the local variable still points at the freed object. xmlXPathFreeObject() reads its type field, which is the use after free, may free what its nodesetval field points to, and frees the object a second time. The fix commit’s message describes the same thing:
xsltTestCompMatchDirect read the cached node-set from the transform context’s runtime extras before calling xmlXPathEval, then freed that pointer afterwards. The evaluation can re-enter the function for the same cache slot (e.g. via a lazily evaluated global variable whose value runs xsl:number), and the nested call may free and replace the cached object, resulting in a double free.
What the stylesheet has to do
Five conditions have to hold.
- XSLT is enabled in the browser.
- An
xsl:numbercount pattern has two consecutive predicates, one of which reads a global variable. - A stale object is already in the pattern’s slot when the outer call starts.
- Three nodes sit in three documents, so that neither call sees the cached document: the source document and two loaded with
document(). - The variable has not been computed before the predicate reads it.
The third condition is the one that needs a trick, because xsl:number clears its count pattern’s cache after every use. Two paths leave an object behind anyway, and they are the same two that the fix commit’s crash test uses.
- union:
xsltCompMatchClearCache()clears only the first alternative ofa | b, so a second alternative that is matched directly keeps its object. - import: slot numbers of template patterns in an imported stylesheet are shifted on import, those of
xsl:numberpatterns are not. A count pattern in a second import then shares a slot with a template pattern of the first, whose cache is never cleared.
This is the stylesheet my PoC serves for the union shape, as the PoC prints it (evidence/poc_stable-vuln_union.txt):
1 | [*] stylesheet served as sheet.xsl: |
Read it with the conditions in mind. $outer numbers the book of the source document, and the direct match caches a node-set for the second alternative of nothing | book[...][...]. Then $outer numbers the book of second.xml. That is a new document, so the outer call takes its copy of the cached pointer and starts evaluating the pattern again. The second predicate reads $inner, which has not been computed yet. Its body loads third.xml and runs the same xsl:number, so the nested call frees the cached object. The outer call comes back holding a pointer to freed memory and frees it again.
A count pattern with a single predicate never enters the function. The PoC has a control variant for that, and it renders normally on the vulnerable build (evidence/poc_stable-vuln_control.txt).
The browser that would not run it
One lab target did not behave like the others. This is the union page against Chrome for Testing 157.0.8103.38 as shipped (evidence/poc_cft-noflag_union.txt):
1 | [*] round 1/1 |
The browser shows the XML and never asks for the stylesheet. That build ships with XSLT off, so a page cannot reach the bug there. With --enable-features=XSLT it crashes like the others, but a lab that needs a switch says nothing about a default install.
The stable-channel .deb is different: 157.0.8103.38 runs XSLT with no switch. So the lab’s main pair is the stable package at 157.0.8103.38 and at 157.0.8103.50, unpacked and run headless in Docker with Chrome’s own sandbox on. One limit belongs here. The lab browsers run with their compiled-in feature defaults and never fetch Google’s live field-trial configuration, which can switch features on or off on a user’s machine. I did not test that.
The crash
poc.py plays the attacker’s web server and the user’s click. It uses the DevTools port only to open the URL and to read what the browser says about its renderer. The payload travels over HTTP like any page. Against stock Chrome 157.0.8103.38 (evidence/poc_stable-vuln_union.txt):
1 | [*] round 1/1 |
The [http] lines are the target’s own requests: the document, the stylesheet, then the two documents that document() pulls in. After third.xml the browser reports that its renderer is gone. Twenty rounds per variant gave 20/20 crashes on 157.0.8103.38.
The verdict above comes from the browser. The renderer also left its own record, a Crashpad minidump (evidence/crash_stable-vuln.txt):
1 | target stable-vuln: Crashpad minidumps written by this browser: 2 |
A ptype=renderer process of version 157.0.8103.38 died with SIGTRAP. The import variant dies with SIGSEGV. And that is all a stock build tells you, because it ships no symbols: the frames are module offsets.
Getting function names
To see which function is at fault I needed a build that names its frames. Chromium publishes AddressSanitizer snapshots of its main branch, and two of them sit exactly where I wanted them: r1738200, the parent of the fix commit, and r1738201, the fix commit itself. The same served documents, against r1738200 (evidence/crash_asan-vuln.txt, report 1 of 2):
1 | --- report 1 of 2 --- |
Read the “freed by” stack from the bottom. The outer call is inside xmlXPathEval() at pattern.c:565. The variable lookup runs the global variable’s body. A nested xsltTestCompMatchDirect() frees the object at line 585. The read at the top is the outer call, back from the evaluation with its stale pointer, in the same line 585.
The second report, for the import shape, has the same read and the same free. What differs is where the stale object was allocated (evidence/crash_asan-vuln.txt, report 2 of 2):
1 | previously allocated by thread T0 (chrome) here: |
In the union case the object was allocated while numbering a node. Here it was allocated by template matching, in xsltGetTemplate(), and later freed through an xsl:number pattern. That is the shared slot.
I want to be exact about what this report is. It comes from a Chromium main-branch snapshot, not from Chrome 157. Lines 565 and 585 are the same there as at tag 157.0.8103.38, but the stock 157 binaries give me no function names. On stock 157, the crash is tied to this function by the negative control and by the sanitizer pair, whose two revisions differ by exactly the fix commit.
The negative control
The same poc.py, the same documents, against Chrome 157.0.8103.50 (evidence/poc_stable-patched_union.txt):
1 | [*] round 1/1 |
The patched browser makes the same four requests, finishes the transform and returns its text. It wrote no crash report, and the sanitizer build at the fix commit printed no report (evidence/crash_stable-patched.txt, evidence/crash_asan-patched.txt):
1 | target stable-patched: Crashpad minidumps written by this browser: 0 |
Twenty rounds per variant against 157.0.8103.50 gave 0/20.
What this shows, and what it does not
| Claim | Status |
|---|---|
Opening the served XML document crashes the renderer of stock Google Chrome 157.0.8103.38 (stable .deb, Linux x86_64, sandbox on, no feature switch) |
Confirmed |
| The same PoC does nothing to 157.0.8103.50 | Confirmed |
The bug is a heap use after free in xmlXPathFreeObject() on a stale pointer held by xsltTestCompMatchDirect(), freed by a nested call reached through a lazily evaluated global variable |
Confirmed on ASAN r1738200 against r1738201, not on Chrome 157 |
| The trigger fires every time | Proven |
| XSLT runs by default in stable 157.0.8103.38 with compiled-in defaults and is off in Chrome for Testing 157.0.8103.38 as shipped | Proven |
| Code execution in the renderer (the disclosed impact), or any controlled use of the freed object | Not reached: not attempted |
| Windows and macOS builds, and versions other than 157.0.8103.38 and 157.0.8103.50 | Not reached: not tested |
| The documents served from a non-loopback origin | Not reached: every run fetched them from http://127.0.0.1:38080 |
| Which variant matches which of the two bug reports the fix closes, and which one the exploit in the wild used | Not reached: unknown and not claimed |
Proven means the evidence file is in the repository. Confirmed means the negative control was run. Not reached means not shown here; it does not mean not possible. The README has the full table with a file for every row, and the list of ways the lab differs from a stock install.
So the gap between disclosed and demonstrated is plain. The record says code execution inside the sandbox. I show a renderer crash on the stock build and the memory error behind it on a sanitizer build.
Detection
The repository ships two rules. Both look for the stylesheet, not for the crash: the XSLT namespace URI, plus an xsl:number whose count or from pattern has two predicates in a row and reads a variable. The Suricata rules match it in an HTTP response body, the YARA rule in a file. There is no Sigma rule, because a stock Chrome leaves only a Crashpad minidump with module offsets, and a renderer crash is not specific to this bug.
The test suite runs 40 checks. Both rules fire once on each of the two live attack captures and stay quiet on the control capture and on a live capture of three ordinary stylesheets rendered by the vulnerable browser. Three things to know before deploying them:
- They are not quiet on everything benign. Both match 2 of the 1128 stylesheets in DocBook XSL 1.79.2, which number footnotes with a multi-predicate count pattern that reads global parameters. That is the trigger’s shape, used harmlessly.
- A long attribute can hide the trigger. Each rule has to cover the stretch from the keyword
countorfromto the two predicates in a single match. The YARA rule stops at 4,096 bytes. For the Suricata rules, with the body in 1400-byte TCP segments, every saved run matched up to 7,500 five-byte union alternatives, about 37.5 kB; above that some runs miss. - The network rule needs to see the stylesheet in clear text, so HTTPS needs TLS inspection. And no variation of my own was run against the lab: the variation evidence is the fix commit’s regression stylesheets, for which the evidence holds no lab run, plus the second live capture and synthetic pcaps.
The rules, their tests, the measured limits and the triage steps for a match are in detection/.
The fix
The fix re-reads the slot after the evaluation, so the outer call frees whatever is in the slot now and not what was there before. It is nine added lines in pattern.c.
For users the fix is the update to 157.0.8103.50. Chrome also defines an enterprise policy, XSLTEnabled, whose definition at tag 157.0.8103.38 says that Disabled makes XSLT unavailable. I read the definition and did not test the policy.
Advisory and fix
| Date | Event |
|---|---|
| 2026-11-07 | Fix commit on the release branch, “[M157-mini] Fix use-after-free in libxslt direct pattern match cache” |
| 2026-11-09 | Stable channel update: Chrome 157.0.8103.50 |
| 2026-11-10 | CVE record published; added to CISA KEV |
| 2026-11-11 | My reproduction runs (UTC) |
The advisory credits the report to Arni Hardarson (Neonix Security) on 2026-10-12 and to an anonymous reporter on 2026-11-06.
Reproduce it
You need a Linux x86_64 host with Docker. From any other machine, add --ssh user@host to the first setup.py command and the lab runs on that host. The first run downloads the pinned Chrome builds and checks each against a sha256.
1 | git clone https://github.com/al4n4n/achilles-heel.git && cd achilles-heel/CVE-2026-125350 |
check.py answers VERDICT: VULNERABLE (confidence: high) for the first target without triggering anything. The first poc.py run ends in RESULT: renderer crash reported by the target in 1/1 rounds -> exit 0, the second, against 157.0.8103.50, in RESULT: no renderer crash in 1/1 rounds -> exit 1. The README lists every step with its expected output, including the sanitizer run and the rule tests, and evidence/INDEX.md lists every evidence file with the command that produced it and the claim it supports.
References
- Repository: al4n4n/achilles-heel/CVE-2026-125350
- Advisory: Chrome Releases, Stable Channel Update for Desktop, 2026-11-09
- CVE record: CVE-2026-125350
- Fix commit: 049750111b1e, which also adds the crash test
xslt-number-pattern-cache-reentrancy-crash.html - Vulnerable function:
xsltTestCompMatchDirect()at tag 157.0.8103.38 XSLTEnabledpolicy definition: at tag 157.0.8103.38