CVE-2026-22218 Chainlit < 2.9.4 Arbitrary File Read via /project/element

High 7.1 Published Updated

An authenticated attacker can read arbitrary files from the server by manipulating path values in the element update flow.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2026-22218?

CVE-2026-22218 is a high-severity path traversal vulnerability in Chainlit, published on 19 Jan 2026. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Chainlit versions prior to 2.9.4 contain an arbitrary file read vulnerability in the /project/element update flow. An authenticated client can send a custom Element with a user-controlled path value, causing the server to copy the referenced file into the attacker’s session. The resulting element identifier (chainlitKey) can then be used to retrieve the file contents via /project/file/<chainlitKey>, allowing disclosure of any file readable by the Chainlit service.

Weakness: CWE-22

Which versions are affected by CVE-2026-22218?

1 open source package ship an affected version, including chainlit. It affects 1 product.

PackageAffectedFixed in
chainlit PyPIAll versions2.9.4

Products include Chainlit Chainlit.

How do I fix CVE-2026-22218?

Upgrade chainlit to 2.9.4 or later.

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

Is CVE-2026-22218 being exploited?

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

Sources

Also known as GHSA-gm79-2pvc-wc75, PYSEC-2026-598.

Is CVE-2026-22218 in your software?

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

Check your SBOMs for free