Downloads · 30 days
4
6% of all-time downloads
Anh1hoa/keras-vulnerability-poc
keras-vulnerability-poc is a machine learning model from Anh1hoa. 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 keras.
This repository contains a Proof of Concept (PoC) model for a critical security vulnerability in the .keras model format.
Downloads · 30 days
4
6% of all-time downloads
All-time downloads
64
Public
Repo size
—
Likes
0
Public
Click a slice to open those files.
.keras13.6 KB · 76%
From the Hugging Face model README
This repository contains a Proof of Concept (PoC) model for a critical security vulnerability in the .keras model format.
The vulnerability allows for Arbitrary Code Execution (ACE) during the model loading process. While industry-standard static analysis tools (e.g., modelscan) focus on detecting unsafe built-in operators like Lambda, they fail to inspect the serialized logic within custom-defined layers registered via register_keras_serializable.
Key Discovery:
modelscan.Run the following command to see the scanner failure:
modelscan -p vantage_stealth_exploit.keras
Expected Result: No issues found! 🎉
import tensorflow as tf
model = tf.keras.models.load_model("vantage_stealth_exploit.keras") Impact This vulnerability poses a significant supply-chain risk. Attackers can distribute malicious models on public hubs that pass all automated security checks, leading to the compromise of developer environments and AI infrastructure.
Disclaimer This model is for educational and security research purposes only. It was created by Nguyen Vo Anh Khoa (Founder CR) as part of a responsible disclosure submitted to Huntr.
License Distributed under the Apache 2.0 License.