← back
CVE-2024-34073

Command Injection in sagemaker-python-sdk

CVSS 7.8 HIGHEPSS 1.1%CWE-78
In short

The sagemaker-python-sdk library has a command injection vulnerability in its capture_dependencies function that can execute arbitrary system commands if a malicious file path is provided as input. An attacker could exploit this to run unauthorized code on the system.

Technical detail

The capture_dependencies function in sagemaker.serve.save_retrive.version_1_0_0.save.utils fails to properly sanitize the 'requirements_path' parameter before passing it to OS command execution, enabling command injection via CWE-78. This allows unauthenticated remote code execution with the privileges of the application, impacting confidentiality, integrity, and availability.

Summary generated and translated by AI from the official description.
sagemaker-python-sdk is a library for training and deploying machine learning models on Amazon SageMaker. In affected versions the capture_dependencies function in `sagemaker.serve.save_retrive.version_1_0_0.save.utils` module allows for potentially unsafe Operating System (OS) Command Injection if inappropriate command is passed as the “requirements_path” parameter. This consequently may allow an unprivileged third party to cause remote code execution, denial of service, affecting both confidentiality and integrity. This issue has been addressed in version 2.214.3. Users are advised to upgrade. Users unable to upgrade should not override the “requirements_path” parameter of capture_dependencies function in `sagemaker.serve.save_retrive.version_1_0_0.save.utils`, and instead use the default value.
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Want to know if your infrastructure is exposed to this?

Talk to TrueHacking →