Downloads · 30 days
0
htdy7703/safetensors-pytorch-safe-open-path-race-poc
safetensors-pytorch-safe-open-path-race-poc is a machine learning model from htdy7703. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This PoC demonstrates a TOCTOU issue in the shipped PyTorch safeopen(..., framework="pt") mmap path.
Downloads · 30 days
0
Access
Public
Updated Jul 8, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py2.3 KB · 50%
From the Hugging Face model README
This PoC demonstrates a TOCTOU issue in the shipped PyTorch safe_open(..., framework="pt") mmap path.
What it shows:
What it does not show:
.safetensors file causing file reads by itself.backend="pread" path or the NumPy loader path.Verified runtime:
safetensors wheel 0.8.0torch 2.12.1+cpuRun:
PYTHONPATH=/mnt/data/huntr/.pydeps-safetensors \
python3 reproduce.py