REDHAT-BUG-2457856: High severity pypi/keras vulnerability
A vulnerability in the TFSMLayer class of the keras package, version 3.13.0, allows attacker-controlled TensorFlow SavedModels to be loaded during deserialization of .keras models, even when safemode=True. This bypasses the security guarantees of safemode and enables arbitrary attacker-controlled code execution during model inference under the victim's privileges. The issue arises due to the unconditional loading of external SavedModels, serialization of attacker-controlled file paths, and the lack of validation in the fromconfig() method.
Affected Software
Event History
Frequently Asked Questions
What is the severity of REDHAT-BUG-2457856?
The severity of REDHAT-BUG-2457856 is classified as high with a score of 7.
How does REDHAT-BUG-2457856 affect the security of my application?
REDHAT-BUG-2457856 allows attacker-controlled models to be loaded despite safe_mode being enabled, compromising security.
What versions of the keras package are affected by REDHAT-BUG-2457856?
REDHAT-BUG-2457856 affects the keras package version 3.13.0.
How do I mitigate the risks associated with REDHAT-BUG-2457856?
To mitigate REDHAT-BUG-2457856, upgrade to a version of keras that has fixed the vulnerability.
What is the impact of REDHAT-BUG-2457856 on TensorFlow models?
REDHAT-BUG-2457856 enables the loading of attacker-controlled TensorFlow SavedModels, which can lead to arbitrary code execution.