Downloads · 30 days
0
0xiviel/poc-pytorch-symint-overflow
poc-pytorch-symint-overflow is a machine learning model from 0xiviel. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
The SymInt version of computeStorageNbytesContiguous at aten/src/ATen/EmptyTensor.cpp:132-139 performs arithmetic on c10::SymInt values without ANY overflow checking, on ALL platforms. The regular (IntArrayRef) versio…
Downloads · 30 days
0
Access
Public
Updated Feb 13, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py14.3 KB · 51%
From the Hugging Face model README
The SymInt version of computeStorageNbytesContiguous at aten/src/ATen/EmptyTensor.cpp:132-139 performs arithmetic on c10::SymInt values without ANY overflow checking, on ALL platforms. The regular (IntArrayRef) version uses safe_multiplies_u64/add_overflows/mul_overflows on desktop builds, but the SymInt version has no such protection.
When SymInt wraps concrete int64_t values, SymInt::operator* (c10/core/SymInt.h:195) performs plain *ma * *mb — signed int64_t multiplication with no overflow check.
poc_symint_overflow.py — Full PoC with 5 tests demonstrating the overflowsymint_overflow_ext.cpp — C++ extension that directly exercises the vulnerable code pathspip install torch
git clone https://huggingface.co/0xiviel/poc-pytorch-symint-overflow
cd poc-pytorch-symint-overflow
python poc_symint_overflow.py
pip install ninja)