Intel

AIKIDO-2024-10370

sentence-transformers is vulnerable to Remote Code Execution (RCE)

Remote Code Execution (RCE) Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Oct 25, 2024

83

High Risk

This Affects:

pythonsentence-transformers
0.0.1 - 3.0.1
Fixed in 3.1.0
Are you affected? Scan for Free

TL;DR

Affected versions of the package are vulnerable to Remote Code Execution (RCE) when loading PyTorch model files. The torch.load() function, when used without the weights_only=True parameter, can deserialize malicious Python objects from manipulated model files, potentially allowing an attacker to execute arbitrary code.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range.

Background info

sentence-transformers is vulnerable to Remote Code Execution (RCE) in versions 0.0.1 - 3.0.1.

How to fix this

Upgrade the sentence-transformers library to the patch version.