Dataset Viewer

The dataset viewer is not available because its heuristics could not detect any supported data files. You can try uploading some data files, or configuring the data files location manually.

YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

PyTorch Package (.ptpkg) ModelScan Bypass → RCE

MFV Target: #38 PyTorch Package ($1500)

Vulnerability

torch.package.PackageExporter.save_pickle() serializes Python objects via pickle.dumps(). The corresponding PackageImporter.load_pickle() deserializes via pickle.loads().

A malicious .ptpkg file containing a pickle payload with __reduce__os.system() triggers RCE at load time.

ModelScan Blind Spot

Two-layer bypass:

  1. Extension not supported: ModelScan only scans .bin, .pt, .pth, .ckpt for PyTorch. .ptpkg is not recognized.

  2. ZIP skip: The PyTorch scanner (PyTorchUnsafeOpScan.scan()) calls _is_zipfile() → return None for ZIP files. .ptpkg is a ZIP archive internally (created by torch._C.PyTorchFileWriter).

Impact

  • CVSS 9.8 (Critical)
  • Remote Code Execution during model loading
  • Supply chain attack: malicious model on HuggingFace → download → PackageImporter.load_pickle() → instant RCE

PoC Files

  • exploit.py — creates malicious.ptpkg and verifies RCE
  • malicious.ptpkg — pre-built PoC file (650+ bytes)

Usage

# Quick test with pre-built file
python3 -c "import torch.package as tpkg; tpkg.PackageImporter('malicious.ptpkg').load_pickle('model', 'model.pkl')"

# Build custom payload
python3 exploit.py
Downloads last month
42