CVE-2023-39659

An issue in langchain langchain-ai v.0.0.232 and before allows a remote attacker to execute arbitrary code via a crafted script to the PythonAstREPLTool._run…

published August 15, 2023

CVSS
—
EPSS
2%
Percentile
74.6
In the wild
Unconfirmed
What it is

⚡ A crafted script can turn into an unexpected guest on the party floor! This vulnerability in langchain-ai v.0.0.232 and earlier could let an attacker execute arbitrary code through the PythonAstREPLTool._run component. Think of it like a waiter who mistakenly serves a dish that wasn't ordered — the kitchen executes commands based on a wrong order slip, creating chaos in the restaurant! Here, the attacker sends their own dish, and the server has no way to verify if it’s safe or not. If exploited, an attacker could run any code they choose, potentially compromising the entire system. This could lead to unauthorized access, data breaches, or even complete control over the affected environment. It's a slippery slope from there!

Put simply

Think of it like a waiter who mistakenly serves a dish that wasn't ordered — the kitchen executes commands based on a wrong order slip, creating chaos in the restaurant! Here, the attacker sends their own dish, and the server has no way to verify if it’s safe or not. This vulnerability allows remote attackers to execute arbitrary code by sending a specially crafted script to the PythonAstREPLTool._run component, which fails to validate inputs properly.

What to do

If exploited, an attacker could run any code they choose, potentially compromising the entire system. This could lead to unauthorized access, data breaches, or even complete control over the affected environment. It's a slippery slope from there! To safeguard against this vulnerability, upgrade to langchain-ai version 0.0.233 or later immediately. Additionally, review your scripts for any unsanitized inputs that could be exploited. Regular audits will help keep your environment safe! You've got this! With these steps, you'll secure your setup in no time. 🛡️

The record
Technical detail
CVSS
Not scored
CVSS v4.0
Not supplied
EPSS
0.01534 · 74.6th percentile
Published
2023-08-15T00:00Z
EPSS history
Timeline
  • 15 AUG 00:00Z
    An issue in langchain langchain-ai v.0.0.232 and before allows a remote attacker to execute arbitrary code via a crafted script to the PythonAstREPLTool._run…
    cvelistv5