Integer overflow in WebML (CVE-2026-3914)
An integer overflow in TFLite's bounds check for ScatterND allows a crafted WebNN model to write up to 512MB of attacker-controlled data past the end of a heap buffer in Chrome's GPU process. An attacker could trigger this from any website if the WebNN feature flag is enabled, potentially leading to sandbox escape.
- Fix shipped in 35 days
Report description
WebNN ScatterND integer overflow in TFLite bounds check allows for 512MB controlled heap OOB write
Bug location
Where do you want to report your vulnerability?
Chrome VRP – Report security issues affecting the Chrome browser. See program rules
Which URL (or repository) have you found the vulnerability in?
https://chromium.googlesource.com/chromium/src/+/main/services/webnn/tflite/graph_builder_tflite.cc
The problem
Please describe the technical details of the vulnerability
Vulnerability Details
SerializeScatterND (graph_builder_tflite.cc:7879) passes runtime indices directly to TFLite with no bounds validation. The other scatter/gather ops either clamp (Gather, GatherND via SerializeGatherIndices) or reject runtime indices entirely (GatherElements, ScatterElements — constant-only).
TFLite's bounds check in reference_ops::ScatterNd (third_party/tflite/src/tensorflow/lite/kernels/internal/reference/reference_ops.h) has an int32 overflow:
if (to_pos < 0 || to_pos + slice_size > output_flat_size) {
return kTfLiteError;
}
With shape=[3, 536870912] int8 and index 3:
to_pos= 1,610,612,736to_pos + slice_size= 2,147,483,648 → wraps to -2,147,483,648- -2,147,483,648 > 1,610,612,736 → false → bypassed
Result: 536,870,912 bytes of attacker-controlled data written past the buffer end. The attacker controls the write content via the updates tensor.
The write occurs in the GPU process.
Bisect: Introduced in b4d4b4cb019bd7240a52daa4ba61e3cc814f0384 (fix for CVE-2022-35939, TF 2.10.0).
Suggested fix:
if (to_pos < 0 || static_cast<int64_t>(to_pos) + slice_size > output_flat_size) {
Version
Chrome: 144.0.7559.110 (Stable), 146.0.7655.0 (Dev)
OS: macOS 15.7.2, Windows 11. Cross-platform.
Flags: --enable-features=WebMachineLearningNeuralNetwork --in-process-gpu
WebNN is behind a flag (W3C spec implementation in progress). --in-process-gpu is for crash visibility only, the bug triggers without it.
Reproduction
- Kill all Chrome instances, relaunch with flags above
- Open
scatternd_heap_oob.html, click "Trigger OOB Write" - Chrome crashes —
EXC_BREAKPOINT / SIGTRAP(PartitionAlloc heap corruption)
Standalone proof (no browser):
clang++ -O2 -fno-strict-overflow -fsanitize=address -g -o bug370_asan bug370_asan_proof.cc
./bug370_asan
Symbolized stack trace (thread 0, main thread):
#0 __pthread_kill + 10
#1 pthread_kill + 259
#2 abort + 126
#3 __sanitizer::Abort() + 88
#4 __sanitizer::Die() + 97
#5 __asan::ScopedInErrorReport::~ScopedInErrorReport() + 1300
#6 __asan::ReportGenericError() + 1782
#7 __asan_report_load1 + 54
#8 ScatterNd_vulnerable() at bug370_asan_proof.cc:98 ← OOB access detected here
#9 test_overflow_exploit() at bug370_asan_proof.cc:191 [inline]
#10 main() at bug370_asan_proof.cc:262
#11 start + 3056
Attachments:
scatternd_heap_oob.html— Browser PoC (59 lines)bug370_asan_proof.cc— Standalone proof, ASanheap-buffer-overflowcrash_chrome_stable.ips— Stable 144 crashcrash_report_chrome_dev.ips— Dev 146 crashcrash_asan_standalone.ips— ASan crash with symbolication
Crash Details
Type: GPU process
Stable 144.0.7559.110 (2/2):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: ThreadPoolSingleThreadSharedForegroundBlocking4
Dev 146.0.7655.0 (5/5):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: ThreadPoolForegroundWorker
Both are PA_IMMEDIATE_CRASH() from PartitionAlloc detecting heap metadata corruption.
lldb on ASan Chromium , the PoC fills the updates tensor with 0x42. Breakpoint on EvalScatterNd<int>, int8 output tensor at 0x29E183840, size 0x60000000. After return, 0x42 appears at every OOB position:
(lldb) memory read -c 64 0x2FE183840
0x2fe183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183850: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183860: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183870: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x30E183840 # +256MB
0x30e183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x31E183840 # +512MB (first byte past the write)
0x31e183840: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
512MB of attacker-controlled 0x42 past the buffer boundary, stopping exactly at slice_size.
Note: ASan Chromium doesn't flag the OOB because TFLite's SimpleMemoryArena allocates a single contiguous buffer for all tensors (~6.4GB), and the OOB write stays within it. The standalone proof uses new[] with normal red zones, so ASan triggers immediately.
Impact analysis
Any website can trigger a 512MB attacker-controlled heap write in Chrome's GPU process if the user has enabled the WebNN feature flag. The attacker controls the write content (via the updates tensor) and the write offset (via the indices tensor). No user interaction is required beyond navigating to the page. The GPU process runs with a weaker sandbox than the renderer and has IPC channels to the browser process, making this a potential stepping stone for sandbox escape.
The cause
What version of Chrome have you found the security issue in?
Stable, Dev
Is the security issue related to a crash?
Yes, it is related to a crash.
Choose the type of vulnerability
Memory Corruption (in a non-sandboxed process)
How would you like to be publicly acknowledged for your report?
cinzinga
Context
This report concerns Google Chrome's WebNN implementation, specifically the WebML component that translates WebNN graphs into TFLite. WebNN is a W3C specification implementation that is still in progress and, at the time of the report, sits behind a feature flag. The vulnerable code lives in the Chromium repository at services/webnn/tflite/graph_builder_tflite.cc, which serialises WebNN operations into TFLite graphs that are then executed by TFLite inside the GPU process.
The operation at the centre of the report is ScatterND. In a scatter operation, an indices tensor selects positions in an output tensor and an updates tensor supplies the values written at those positions. The serialiser SerializeScatterND (cited at graph_builder_tflite.cc:7879) passes runtime indices straight through to TFLite without any bounds validation.
The researcher notes that this is inconsistent with the other scatter and gather operations in the same builder: Gather and GatherND clamp indices via SerializeGatherIndices, while GatherElements and ScatterElements reject runtime indices entirely and accept constant indices only. ScatterND is the outlier that forwards runtime indices unchecked.
Setup
The report lists the following environment and preconditions.
- Chrome versions: 144.0.7559.110 (Stable) and 146.0.7655.0 (Dev).
- Operating systems: macOS 15.7.2 and Windows 11. The researcher states the issue is cross-platform.
- Flags:
--enable-features=WebMachineLearningNeuralNetwork --in-process-gpu
WebNN is behind a flag because the W3C spec implementation is in progress. The researcher states that --in-process-gpu is used for crash visibility only and that the bug triggers without it.
- Reproduction steps given: kill all Chrome instances, relaunch with the flags above, open
scatternd_heap_oob.htmland click "Trigger OOB Write". - Attachments listed:
scatternd_heap_oob.html(browser PoC, 59 lines),bug370_asan_proof.cc(standalone proof producing an ASanheap-buffer-overflow),crash_chrome_stable.ips(Stable 144 crash),crash_report_chrome_dev.ips(Dev 146 crash) andcrash_asan_standalone.ips(ASan crash with symbolication).
No accounts or roles are involved. The precondition for a real-world trigger is that the user has enabled the WebNN feature flag.
Finding it
The researcher identified an int32 overflow in TFLite's bounds check inside reference_ops::ScatterNd, located at third_party/tflite/src/tensorflow/lite/kernels/internal/reference/reference_ops.h:
if (to_pos < 0 || to_pos + slice_size > output_flat_size) {
return kTfLiteError;
}
The check computes to_pos + slice_size in 32-bit arithmetic. If the sum exceeds the maximum int32 value it wraps to a negative number, and the comparison against output_flat_size then evaluates false, so the error is not returned and the write proceeds.
The researcher gives a concrete worked example with an int8 tensor of shape=[3, 536870912] and index 3:
to_pos= 1,610,612,736to_pos + slice_size= 2,147,483,648, which wraps to -2,147,483,648- -2,147,483,648 > 1,610,612,736 evaluates to false, so the check is bypassed
The result is 536,870,912 bytes (512MB) of attacker-controlled data written past the end of the buffer. The content of the write is controlled through the updates tensor. The write happens in the GPU process.
The researcher bisected the issue to commit [redacted], described as the fix for CVE-2022-35939 in TensorFlow 2.10.0. In other words, the overflow was introduced by an earlier bounds-check fix.
Exploitation
Step 1: launch Chrome with the WebNN flag
--enable-features=WebMachineLearningNeuralNetwork --in-process-gpu
The first flag enables the WebNN feature, which is otherwise off. The second runs the GPU process in-process, which the researcher says is only for crash visibility; the bug triggers without it.
Step 2: load the browser PoC and trigger the write
Open scatternd_heap_oob.html and click "Trigger OOB Write". Chrome crashes with EXC_BREAKPOINT / SIGTRAP.
Chrome crashes with EXC_BREAKPOINT / SIGTRAP, which the researcher attributes to PartitionAlloc heap corruption.
Step 3: confirm with the standalone proof
The researcher also provides a browser-free proof, compiled and run as follows:
clang++ -O2 -fno-strict-overflow -fsanitize=address -g -o bug370_asan bug370_asan_proof.cc
./bug370_asan
The build uses AddressSanitizer and the -fno-strict-overflow flag; the report does not explain the flag. The resulting symbolised stack trace (thread 0, main thread) is:
#0 __pthread_kill + 10
#1 pthread_kill + 259
#2 abort + 126
#3 __sanitizer::Abort() + 88
#4 __sanitizer::Die() + 97
#5 __asan::ScopedInErrorReport::~ScopedInErrorReport() + 1300
#6 __asan::ReportGenericError() + 1782
#7 __asan_report_load1 + 54
#8 ScatterNd_vulnerable() at bug370_asan_proof.cc:98 ← OOB access detected here
#9 test_overflow_exploit() at bug370_asan_proof.cc:191 [inline]
#10 main() at bug370_asan_proof.cc:262
#11 start + 3056
The frame at bug370_asan_proof.cc:98 is where ASan detects the out-of-bounds access.
Step 4: observe the crash in both channels
The report records crash details for both versions.
Stable 144.0.7559.110 (2 out of 2 attempts):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: [redacted]
Dev 146.0.7655.0 (5 out of 5 attempts):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: ThreadPoolForegroundWorker
Both are described as PA_IMMEDIATE_CRASH() from PartitionAlloc detecting heap metadata corruption.
Step 5: inspect memory under lldb
On an ASan Chromium build, the PoC fills the updates tensor with 0x42. The researcher sets a breakpoint on EvalScatterNd<int>; the int8 output tensor is at 0x29E183840 with size 0x60000000. After the call returns, 0x42 appears at every out-of-bounds position:
(lldb) memory read -c 64 0x2FE183840
0x2fe183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183850: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183860: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183870: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x30E183840 # +256MB
0x30e183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x31E183840 # +512MB (first byte past the write)
0x31e183840: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
This shows 512MB of attacker-controlled 0x42 past the buffer boundary, stopping exactly at slice_size.
The researcher adds an important limit: ASan Chromium does not flag the out-of-bounds write because TFLite's SimpleMemoryArena allocates a single contiguous buffer for all tensors (about 6.4GB), and the out-of-bounds write stays inside it. The standalone proof uses new[] with normal red zones, so ASan triggers immediately there.
Root cause
The bounds check in reference_ops::ScatterNd performs the addition to_pos + slice_size in int32. When the sum exceeds the int32 maximum it wraps negative, and the comparison > output_flat_size is then false, so the function returns success instead of kTfLiteError. The write that follows is not clamped.
On the Chrome side, SerializeScatterND forwards runtime indices to TFLite without bounds validation, unlike the other scatter and gather serialisers, which either clamp indices or accept constants only. That means a web page can supply the index values that drive the overflow.
The researcher notes that ASan in Chromium also does not catch the write in the browser build because the TFLite arena places all tensors in one large contiguous allocation, so the write lands inside allocated memory from ASan's point of view. Both recorded crashes are described as PA_IMMEDIATE_CRASH() from PartitionAlloc detecting heap metadata corruption.
Impact
The researcher's impact statement: any website can trigger a 512MB attacker-controlled heap write in Chrome's GPU process if the user has enabled the WebNN feature flag. The attacker controls the write content via the updates tensor and the write offset via the indices tensor. No user interaction is required beyond navigating to the page. The GPU process runs with a weaker sandbox than the renderer and has IPC channels to the browser process, which the researcher describes as making this a potential stepping stone for sandbox escape.
The report classifies the issue as Memory Corruption in a non-sandboxed process and as related to a crash. The platform facts record a severity of high and a bounty of 43,000.00 USD; the report text itself does not state a CVSS score.
Fix
The researcher proposes a single-line change that widens the addition to 64-bit before comparing:
if (to_pos < 0 || static_cast<int64_t>(to_pos) + slice_size > output_flat_size) {
The report does not state which fix, if any, was actually applied upstream. The platform facts list the item as an advisory disclosed on 2026-03-10 under CVE-2026-3914.
Variants to test
- Other TFLite kernels with int32 offset arithmetic. Look for bounds checks of the form
offset + size > limitcomputed in int32 in gather, scatter, slice, strided slice or padding kernels. A positive result is a check that can be made to wrap by choosing a large shape and index, with the wrapped value comparing false against the limit. - Other WebNN serialisers that pass runtime indices. The report contrasts ScatterND with Gather, GatherND, GatherElements and ScatterElements. Test any operation that accepts runtime indices and forwards them to TFLite, checking whether indices are clamped or validated. A positive result is an operation whose runtime indices reach TFLite unvalidated.
- Large-shape arithmetic in graph builders. Try shapes whose element counts approach or exceed 2^31 in other builders, not only ScatterND. A positive result is an allocation or offset computation that overflows and produces a smaller allocation than the operation writes to.
- Arena layout assumptions. The report notes that TFLite's
SimpleMemoryArenaplaces all tensors in one contiguous buffer, which hid the write from ASan in Chromium. Test whether other out-of-bounds writes stay inside the arena and therefore escape sanitizer detection, using a standalone build with normal red zones to confirm. - Feature-flag gated surfaces. WebNN was behind
--enable-features=WebMachineLearningNeuralNetwork. Enumerate other in-progress features behind flags that expose new parsers or serialisers to web content, and check their input validation. A positive result is a flag-gated path that accepts attacker-controlled sizes or indices without bounds checks.
What happened, in plain words
A security researcher found a bug in Google Chrome, the web browser. If the WebNN feature flag is enabled, any website can write a large amount of data it chooses past the end of a buffer in Chrome's GPU process. The amount is 512MB. The write happens in a background helper program that Chrome uses for graphics work, called the GPU process. That helper has fewer protections than the part of Chrome that runs web pages, so the researcher describes the bug as a possible first step towards breaking out of Chrome's security sandbox.
The bug only works if the person using Chrome has switched on an experimental feature called WebNN. WebNN is a draft standard for running machine learning inside the browser. At the time of the report it was hidden behind a setting (a "feature flag") because it is still being built. So the bug is real but not reachable on a default Chrome install.
The root cause is a small arithmetic mistake. A safety check in a library called TFLite (TensorFlow Lite, a toolkit for running machine learning models) adds two numbers together using a 32-bit integer, a number type that can only hold values up to about 2.1 billion. When the sum goes past that limit, it "wraps around" and becomes a large negative number. The check then compares that negative number against the buffer size, decides everything is fine, and lets the write go ahead. The write lands far outside the intended memory area.
The report includes a web page that crashes Chrome, a standalone C++ program that ASan flags, and an lldb session on an ASan Chromium build showing 0x42 past the buffer end. The report also proposes a one-line fix.
Context
This section explains the pieces involved before the bug itself.
Chrome is the browser. Internally it is split into several processes (separate programs) so that a problem in one does not automatically compromise the others. The renderer process runs the web page's code. The GPU process handles graphics and, in this case, also runs the machine learning work. Processes talk to each other through IPC (inter-process communication), a set of internal message channels.
WebNN is a proposed standard from the W3C (the body that writes web standards) for letting web pages use neural networks, which are the maths behind modern machine learning. The implementation in Chrome was still in progress, so it was placed behind a feature flag: a switch that is off by default and can be turned on with a command-line option. Think of it like a hidden menu in a game that only opens if you type a special code.
WebML is the name of the Chrome component that implements this. Part of its job is to translate the operations a web page asks for into a form that TFLite can execute. TFLite is a small, embeddable version of TensorFlow, a popular machine learning library. The translation code lives in the Chromium source repository at:
services/webnn/tflite/graph_builder_tflite.cc
That file is a serialiser: it takes a description of a computation and writes it out in another format. Here it writes WebNN operations into a TFLite graph, which TFLite then runs inside the GPU process.
The operation at the centre of the report is ScatterND. A scatter operation takes two inputs: an indices tensor and an updates tensor. A tensor is just a multi-dimensional array of numbers, like a spreadsheet with more than two dimensions. The indices tensor says where to write, and the updates tensor says what to write. Imagine a grid of postboxes: indices lists which postboxes to open, and updates holds the letters you drop in.
The serialiser function SerializeScatterND, cited at graph_builder_tflite.cc:7879, passes the indices supplied at runtime straight through to TFLite without checking them. "At runtime" means the values come from the web page while it is running, not from a fixed list baked into the code.
The researcher points out that this is inconsistent with the other similar operations in the same file. Gather and GatherND clamp their indices (clamping means forcing a value into an allowed range, like a volume knob that cannot go past maximum). GatherElements and ScatterElements refuse runtime indices altogether and only accept constant ones. ScatterND is the odd one out: it forwards runtime indices with no check at all.
Setup
The report lists the following environment and preconditions.
- Chrome versions: 144.0.7559.110 (Stable) and 146.0.7655.0 (Dev). "Stable" is the normal release channel; "Dev" is the early, less-tested channel used by developers.
- Operating systems: macOS 15.7.2 and Windows 11. The researcher states the issue is cross-platform, meaning it is not tied to one operating system.
- Flags:
--enable-features=WebMachineLearningNeuralNetwork --in-process-gpu
This is a command-line option string. The first part, --enable-features=WebMachineLearningNeuralNetwork, turns on the WebNN feature, which is otherwise off. The second part, --in-process-gpu, is, per the researcher, only for crash visibility; the bug triggers without it. The researcher says this second flag is only there so crashes are easier to see; the bug triggers without it.
- Reproduction steps given: kill all Chrome instances, relaunch with the flags above, open
scatternd_heap_oob.htmland click "Trigger OOB Write". "OOB" stands for out-of-bounds, meaning outside the intended memory area. - Attachments listed:
scatternd_heap_oob.html(browser proof of concept, 59 lines),bug370_asan_proof.cc(standalone proof producing an ASanheap-buffer-overflow),crash_chrome_stable.ips(Stable 144 crash),crash_report_chrome_dev.ips(Dev 146 crash) andcrash_asan_standalone.ips(ASan crash with symbolication). A proof of concept (PoC) is a small demonstration that shows a bug is real. ASan (AddressSanitizer) is a tool built into a program that watches memory accesses and shouts when one goes out of bounds. A crash report (.ipsfile) is the record a program writes when it dies. Symbolication means turning raw memory addresses in a crash report into human-readable function names.
No accounts or roles are involved. The precondition for a real-world trigger is that the user has enabled the WebNN feature flag.
Finding it
The researcher identified an integer overflow in TFLite's bounds check inside reference_ops::ScatterNd, located at:
third_party/tflite/src/tensorflow/lite/kernels/internal/reference/reference_ops.h
An integer overflow is what happens when you do arithmetic on a fixed-size number and the result does not fit. A 32-bit signed integer (often called int32) can hold values from about -2.1 billion to +2.1 billion. Add one to the maximum and it wraps around to the minimum, like a car odometer rolling from 999999 back to 000000. The bounds check looks like this:
if (to_pos < 0 || to_pos + slice_size > output_flat_size) {
return kTfLiteError;
}
Line by line:
if (to_pos < 0 || ...): if the starting position is negative, or the second condition is true, then...to_pos + slice_size > output_flat_size: ...if the start plus the size of the piece to write is larger than the total buffer size, then...return kTfLiteError;: ...stop and report an error instead of writing.
The problem is that to_pos + slice_size is computed in 32-bit arithmetic. If the sum goes past the int32 maximum, it wraps to a negative number. A negative number is never greater than output_flat_size, so the comparison is false, the error is not returned, and the write goes ahead.
The researcher gives a concrete worked example with an int8 tensor of shape=[3, 536870912] and index 3. An int8 tensor stores each element in one byte, a value from -128 to 127. The shape says the tensor has 3 rows of 536,870,912 elements each.
to_pos= 1,610,612,736. This is the byte offset where the write is supposed to start.to_pos + slice_size= 2,147,483,648, which wraps to -2,147,483,648. That is exactly 2^31, one past the int32 maximum, so it flips to the most negative int32 value.- -2,147,483,648 > 1,610,612,736 evaluates to false, so the check is bypassed.
The result is 536,870,912 bytes (512MB) of attacker-controlled data written past the end of the buffer. The content of the write is controlled through the updates tensor. The write happens in the GPU process.
The researcher bisected the issue to a specific commit. A bisect is a way of searching through the history of a codebase to find the exact change that introduced a bug, like halving a list of suspects until one remains. The commit is [redacted], described as the fix for CVE-2022-35939 in TensorFlow 2.10.0. A CVE is a public identifier for a known vulnerability. In other words, the overflow was introduced by the commit that fixed CVE-2022-35939.
Exploitation
Step 1: launch Chrome with the WebNN flag
--enable-features=WebMachineLearningNeuralNetwork --in-process-gpu
This is the same flag string as in the setup. The first flag enables the WebNN feature, which is otherwise off. The second runs the GPU process in-process, which the researcher says is only for crash visibility; the bug triggers without it.
Step 2: load the browser PoC and trigger the write
Open scatternd_heap_oob.html and click "Trigger OOB Write". The page builds a WebNN ScatterND operation whose indices reach TFLite unchecked, with the updates tensor supplying the bytes written out of bounds.
Chrome crashes with EXC_BREAKPOINT / SIGTRAP, which the researcher attributes to PartitionAlloc heap corruption. PartitionAlloc is Chrome's own memory allocator, the component that hands out chunks of memory and keeps track of which chunks are in use. A heap is the pool of memory a program uses for data it creates while running. Heap corruption means the bookkeeping data that the allocator keeps next to each chunk has been overwritten. EXC_BREAKPOINT and SIGTRAP are the operating system's way of saying the program hit a deliberate stop, which is what PartitionAlloc does when it notices its own records are damaged.
Step 3: confirm with the standalone proof
The researcher also provides a browser-free proof, compiled and run as follows:
clang++ -O2 -fno-strict-overflow -fsanitize=address -g -o bug370_asan bug370_asan_proof.cc
./bug370_asan
Line by line:
clang++: the C++ compiler.-O2: ask for a normal level of optimisation.-fno-strict-overflow: tell the compiler not to assume that signed integer overflow never happens. Without this, the compiler might optimise away the very behaviour being demonstrated.-fsanitize=address: build in AddressSanitizer, the memory checker.-g: include debugging information so the crash report shows function names and line numbers.-o bug370_asan: name the output programbug370_asan.bug370_asan_proof.cc: the source file to compile../bug370_asan: run the resulting program.
The resulting symbolised stack trace (thread 0, main thread) is:
#0 __pthread_kill + 10
#1 pthread_kill + 259
#2 abort + 126
#3 __sanitizer::Abort() + 88
#4 __sanitizer::Die() + 97
#5 __asan::ScopedInErrorReport::~ScopedInErrorReport() + 1300
#6 __asan::ReportGenericError() + 1782
#7 __asan_report_load1 + 54
#8 ScatterNd_vulnerable() at bug370_asan_proof.cc:98 ← OOB access detected here
#9 test_overflow_exploit() at bug370_asan_proof.cc:191 [inline]
#10 main() at bug370_asan_proof.cc:262
#11 start + 3056
A stack trace is a list of the function calls that led to the crash, newest at the top. Reading from the bottom up: start is the program entry point, main is the program's main function, test_overflow_exploit is the test function, and ScatterNd_vulnerable is the function containing the bug. The frames above it (__asan_report_load1, __asan::ReportGenericError, abort, pthread_kill) are the memory checker noticing the problem and deliberately stopping the program. The frame at bug370_asan_proof.cc:98 is where ASan detects the out-of-bounds access.
Step 4: observe the crash in both channels
The report records crash details for both versions.
Stable 144.0.7559.110 (2 out of 2 attempts):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: [redacted]
Dev 146.0.7655.0 (5 out of 5 attempts):
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Termination Reason: Trace/BPT trap: 5
Faulting Thread: ThreadPoolForegroundWorker
Line by line:
Exception Type: EXC_BREAKPOINT (SIGTRAP): the kind of stop the operating system reported. A breakpoint is a deliberate halt.Termination Reason: Trace/BPT trap: 5: the reason code attached to the stop.Faulting Thread: ...: which thread (a thread is a unit of execution inside a program) was running when it stopped. The two versions show different faulting thread names.
Both are described as PA_IMMEDIATE_CRASH() from PartitionAlloc detecting heap metadata corruption. "Metadata" here means the allocator's own records about which chunks are free or in use. When those records are overwritten, the allocator stops the program on purpose rather than continue in an unsafe state.
Step 5: inspect memory under lldb
On an ASan Chromium build, the PoC fills the updates tensor with 0x42. 0x42 is the hexadecimal notation for the byte value 66, which happens to be the ASCII code for the capital letter B. Using a distinctive byte makes it easy to spot in memory. The researcher sets a breakpoint on EvalScatterNd<int>; a breakpoint is a deliberate pause in a debugger so you can look around. lldb is the debugger being used. The int8 output tensor is at 0x29E183840 with size 0x60000000. Those are memory addresses and sizes in hexadecimal; 0x60000000 is 1,610,612,736 bytes, matching the to_pos figure earlier. After the call returns, 0x42 appears at every out-of-bounds position:
(lldb) memory read -c 64 0x2FE183840
0x2fe183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183850: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183860: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
0x2fe183870: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x30E183840 # +256MB
0x30e183840: 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 BBBBBBBBBBBBBBBB
(lldb) memory read -c 16 0x31E183840 # +512MB (first byte past the write)
0x31e183840: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
Line by line:
(lldb) memory read -c 64 0x2FE183840: ask the debugger to read 64 bytes starting at that address. The output shows the byte42repeated, with the right-hand column showing the printable characterB.(lldb) memory read -c 16 0x30E183840 # +256MB: read 16 bytes at an address 256MB further along. Still42, so the write reached at least this far.(lldb) memory read -c 16 0x31E183840 # +512MB (first byte past the write): read 16 bytes at an address 512MB past the start. Now the bytes are00, meaning the write stopped exactly there.
This shows 512MB of attacker-controlled 0x42 past the buffer boundary, stopping exactly at slice_size.
The researcher adds an important limit: ASan Chromium does not flag the out-of-bounds write because TFLite's SimpleMemoryArena allocates a single contiguous buffer for all tensors (about 6.4GB), and the out-of-bounds write stays inside it. An arena is a memory-management pattern where one big block is reserved up front and handed out in pieces. Because the whole arena is one allocation from ASan's point of view, a write that leaves one tensor but stays inside the arena looks legal. The standalone proof uses new[] with normal red zones, so ASan triggers immediately there. A red zone is a small guard area ASan places around each allocation; writing into it is how ASan notices an overflow.
Root cause
The bounds check in reference_ops::ScatterNd performs the addition to_pos + slice_size in int32. When the sum exceeds the int32 maximum it wraps negative, and the comparison > output_flat_size is then false, so the function returns success instead of kTfLiteError. The write that follows is not clamped.
On the Chrome side, SerializeScatterND forwards runtime indices to TFLite without bounds validation, unlike the other scatter and gather serialisers, which either clamp indices or accept constants only. That means a web page can supply the index values that drive the overflow.
The existing defences did not stop it: the TFLite bounds check is the defence, and its int32 arithmetic is exactly what fails. The researcher notes that ASan in Chromium also does not catch the write in the browser build because the TFLite arena places all tensors in one large contiguous allocation, so the write lands inside allocated memory from ASan's point of view. The crash that does occur comes from PartitionAlloc detecting heap metadata corruption.
Impact
The researcher's impact statement: any website can trigger a 512MB attacker-controlled heap write in Chrome's GPU process if the user has enabled the WebNN feature flag. The attacker controls the write content via the updates tensor and the write offset via the indices tensor. No user interaction is required beyond navigating to the page. The GPU process runs with a weaker sandbox than the renderer and has IPC channels to the browser process, which the researcher describes as making this a potential stepping stone for sandbox escape.
A sandbox is a set of restrictions that limits what a process can do, so that a bug in that process does less damage. The GPU process has a weaker sandbox than the renderer. The GPU process has a weaker one because it needs more access to do graphics work. A sandbox escape is the step where an attacker who has already broken into one process uses that foothold to reach something more privileged. The report classifies the issue as Memory Corruption in a non-sandboxed process and as related to a crash. The platform facts record a severity of high and a bounty of 43,000.00 USD; the report text itself does not state a CVSS score. CVSS is a standard scoring system for vulnerability severity.
Fix
The researcher proposes a single-line change that widens the addition to 64-bit before comparing:
if (to_pos < 0 || static_cast<int64_t>(to_pos) + slice_size > output_flat_size) {
Line by line:
static_cast<int64_t>(to_pos): convertto_posto a 64-bit integer before the addition. A 64-bit integer can hold values up to about 9.2 quintillion, far beyond any realistic buffer size, so the sum cannot wrap.+ slice_size: add the slice size in 64-bit arithmetic.> output_flat_size: compare against the buffer size. Now the comparison is meaningful.
The report does not state which fix, if any, was actually applied upstream. The platform facts list the item as an advisory disclosed on 2026-03-10 under CVE-2026-3914.
Variants to test
This section lists other places a researcher might look for similar bugs. Each item explains what to try and what a positive result would look like.
- Other TFLite kernels with int32 offset arithmetic. Look for bounds checks of the form
offset + size > limitcomputed in int32 in gather, scatter, slice, strided slice or padding kernels. A positive result is a check that can be made to wrap by choosing a large shape and index, with the wrapped value comparing false against the limit. - Other WebNN serialisers that pass runtime indices. The report contrasts ScatterND with Gather, GatherND, GatherElements and ScatterElements. Test any operation that accepts runtime indices and forwards them to TFLite, checking whether indices are clamped or validated. A positive result is an operation whose runtime indices reach TFLite unvalidated.
- Large-shape arithmetic in graph builders. Try shapes whose element counts approach or exceed 2^31 in other builders, not only ScatterND. A positive result is an allocation or offset computation that overflows and produces a smaller allocation than the operation writes to.
- Arena layout assumptions. The report notes that TFLite's
SimpleMemoryArenaplaces all tensors in one contiguous buffer, which hid the write from ASan in Chromium. Test whether other out-of-bounds writes stay inside the arena and therefore escape sanitizer detection, using a standalone build with normal red zones to confirm. - Feature-flag gated surfaces. WebNN was behind
--enable-features=WebMachineLearningNeuralNetwork. Enumerate other in-progress features behind flags that expose new parsers or serialisers to web content, and check their input validation. A positive result is a flag-gated path that accepts attacker-controlled sizes or indices without bounds checks.
Glossary
- API: a defined way for one piece of software to ask another to do something, like a menu of allowed requests.
- Arena: a memory-management pattern where one large block is reserved and handed out in pieces, so individual allocations are not tracked separately.
- ASan (AddressSanitizer): a tool built into a program that watches memory accesses and reports out-of-bounds reads and writes.
- Bisect: a search through a codebase's history that halves the range of candidate changes until the one that introduced a bug is found.
- Bounds check: code that verifies a position or size stays inside an allowed range before using it.
- Breakpoint: a deliberate pause in a debugger so the programmer can inspect the program's state.
- Buffer: a block of memory set aside to hold data.
- Clamp: force a value into an allowed range, like a volume knob that cannot go past maximum.
- Commit: a recorded change in a version-control system such as Git.
- Crash report: the record a program writes when it stops unexpectedly.
- CVE: a public identifier for a known vulnerability.
- CVSS: a standard scoring system for vulnerability severity.
- Feature flag: a switch that turns an unfinished feature on or off, usually off by default.
- GPU process: the Chrome process that handles graphics work and, in this case, machine learning execution.
- Heap: the pool of memory a program uses for data it creates while running.
- Heap corruption: damage to the bookkeeping data an allocator keeps next to each chunk of memory.
- Indices tensor: the input that says where a scatter or gather operation should read or write.
- Integer overflow: what happens when arithmetic on a fixed-size number produces a result too large to fit, so the value wraps around.
- int8 / int32 / int64: integer types of 8, 32 and 64 bits. int32 holds roughly -2.1 billion to +2.1 billion; int64 holds far more.
- IPC: inter-process communication, the internal message channels processes use to talk to each other.
- lldb: a debugger used to pause and inspect programs.
- Metadata: data about data; here, the allocator's own records about which memory chunks are free or in use.
- Out-of-bounds (OOB): outside the intended memory area.
- PartitionAlloc: Chrome's own memory allocator.
- Proof of concept (PoC): a small demonstration that shows a bug is real.
- Red zone: a small guard area ASan places around each allocation; writing into it is how ASan notices an overflow.
- Renderer process: the Chrome process that runs the web page's code.
- Sandbox: a set of restrictions that limits what a process can do.
- Sandbox escape: using a foothold in one process to reach something more privileged.
- ScatterND: a tensor operation where an indices tensor selects positions and an updates tensor supplies the values written there.
- Serialiser: code that takes a description of a computation and writes it out in another format.
- Shape: the dimensions of a tensor, for example 3 rows of 536,870,912 elements.
- SimpleMemoryArena: TFLite's arena implementation, which places all tensors in one contiguous buffer.
- Stack trace: a list of the function calls that led to a crash, newest at the top.
- Symbolication: turning raw memory addresses in a crash report into human-readable function names.
- Tensor: a multi-dimensional array of numbers.
- TFLite (TensorFlow Lite): a small, embeddable version of the TensorFlow machine learning library.
- Thread: a unit of execution inside a program.
- Updates tensor: the input that supplies the values a scatter operation writes.
- WebML: the Chrome component that implements WebNN.
- WebNN: a proposed W3C standard for letting web pages use neural networks.
- W3C: the body that writes web standards.