Downloads · 30 days
0
0xiviel/poc-pytorch-jit-negnumel
poc-pytorch-jit-negnumel 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.
Vulnerability: unpickler.cpp:570 uses if (numel 0) to guard storage data reads. A numel value of 0 in the pickle stream bypasses this check, creating a Storage with NULL data pointer. rebuildTensor then restores the o…
Downloads · 30 days
0
Access
Public
Updated Feb 13, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py28.1 KB · 92%
From the Hugging Face model README
Vulnerability: unpickler.cpp:570 uses if (numel > 0) to guard storage data reads. A numel value of 0 in the pickle stream bypasses this check, creating a Storage with NULL data pointer. rebuildTensor then restores the original shape {2,4}, creating a tensor that claims 8 float32 elements backed by 0 bytes at NULL. Any tensor operation crashes with SIGSEGV.
poc_zero_numel.py — Full PoC (null storage demo, SIGSEGV crash, comparison, code analysis)pip install torch
python poc_zero_numel.py