Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

nvd логотип

CVE-2025-9905

Опубликовано: 19 сент. 2025
Источник: nvd
CVSS3: 7.3
EPSS Низкий

Описание

The Keras Model.load_model method can be exploited to achieve arbitrary code execution, even with safe_mode=True.

One can create a specially crafted .h5/.hdf5 model archive that, when loaded via Model.load_model, will trigger arbitrary code to be executed.

This is achieved by crafting a special .h5 archive file that uses the Lambda layer feature of keras which allows arbitrary Python code in the form of pickled code. The vulnerability comes from the fact that the safe_mode=True option is not honored when reading .h5 archives.

Note that the .h5/.hdf5 format is a legacy format supported by Keras 3 for backwards compatibility.

Уязвимые конфигурации

Конфигурация 1
cpe:2.3:a:keras:keras:*:*:*:*:*:*:*:*
Версия от 3.0.0 (включая) до 3.11.3 (исключая)

EPSS

Процентиль: 0%
0.00006
Низкий

7.3 High

CVSS3

Дефекты

CWE-913

Связанные уязвимости

CVSS3: 7.3
ubuntu
2 месяца назад

The Keras Model.load_model method can be exploited to achieve arbitrary code execution, even with safe_mode=True. One can create a specially crafted .h5/.hdf5 model archive that, when loaded via Model.load_model, will trigger arbitrary code to be executed. This is achieved by crafting a special .h5 archive file that uses the Lambda layer feature of keras which allows arbitrary Python code in the form of pickled code. The vulnerability comes from the fact that the safe_mode=True option is not honored when reading .h5 archives. Note that the .h5/.hdf5 format is a legacy format supported by Keras 3 for backwards compatibility.

CVSS3: 8.6
redhat
2 месяца назад

The Keras Model.load_model method can be exploited to achieve arbitrary code execution, even with safe_mode=True. One can create a specially crafted .h5/.hdf5 model archive that, when loaded via Model.load_model, will trigger arbitrary code to be executed. This is achieved by crafting a special .h5 archive file that uses the Lambda layer feature of keras which allows arbitrary Python code in the form of pickled code. The vulnerability comes from the fact that the safe_mode=True option is not honored when reading .h5 archives. Note that the .h5/.hdf5 format is a legacy format supported by Keras 3 for backwards compatibility.

CVSS3: 7.3
msrc
2 месяца назад

Arbitary Code execution in Keras load_model()

CVSS3: 7.3
debian
2 месяца назад

The Keras Model.load_modelmethod can be exploited to achieve arbitrary ...

github
2 месяца назад

The Keras `Model.load_model` method **silently** ignores `safe_mode=True` and allows arbitrary code execution when a `.h5`/`.hdf5` file is loaded.

EPSS

Процентиль: 0%
0.00006
Низкий

7.3 High

CVSS3

Дефекты

CWE-913