CVE-2024-8438 Path Traversal in modelscope/agentscope

High 7.5 Published Updated

Attackers can read arbitrary files on the server via unsanitized path parameters in the file API endpoint of the Agentscope library.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2024-8438?

CVE-2024-8438 is a high-severity path traversal vulnerability in modelscope/agentscope, published on 20 Mar 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

A path traversal vulnerability exists in modelscope/agentscope version v.0.0.4. The API endpoint `/api/file` does not properly sanitize the `path` parameter, allowing an attacker to read arbitrary files on the server.

Weakness: CWE-22

Which versions are affected by CVE-2024-8438?

3 open source packages ship an affected version, including agentscope. It affects 1 product.

PackageAffectedFixed in
agentscope PyPIAll versions to 0.0.4None
agentscope PyPIAll versions to 0.0.4None
agentscope PyPIAll versions to 0.0.4None

Products include Modelscope Agentscope.

How do I fix CVE-2024-8438?

No fix has been published for CVE-2024-8438 yet. Limit exposure of the affected software until one is available.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2024-8438 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-8438 exists.

Sources

Also known as GHSA-f4hc-q562-cc5r, PYSEC-2025-80.

Is CVE-2024-8438 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free