# Chainlit <2.9.4 项目文件读取漏洞
## 概述
Chainlit 在 2.9.4 版本之前存在任意文件读取漏洞,位于 `/project/element` 更新流程中。
## 影响版本
Chainlit 版本早于 2.9.4
## 细节
经过身份验证的客户端可发送包含用户控制路径的自定义 Element,导致服务器将该路径指向的文件复制到攻击者的会话中。生成的元素标识符(chainlitKey)可用于通过 `/project/file/<chainlitKey>` 接口下载该文件。
## 影响
攻击者可读取 Chainlit 服务有权限访问的任意文件,导致敏感信息泄露。
是否为 Web 类漏洞: 未知
判断理由:
| # | POC 描述 | 源链接 | 神龙链接 |
|---|
标题: Release 2.9.4 · Chainlit/chainlit · GitHub -- 🔗来源链接
标签:release-notespatch
神龙速读:
- **Security Vulnerability Fix**
- A security vulnerability was fixed in this release (#2737)
- Regarding custom thread element updates
### Breaking Changes
- If persistence is used, the `ALTER TABLE steps ADD COLUMN IF NOT EXISTS modes JSONB;` command needs to be executed to ensure a smooth migration process
### Additions
- Shared thread icons were added by @Allaoua9 (#2715)
- A new option to disable auto-scroll of assistant messages was introduced by @jfperusse (#2724)
- Add modes feature was implemented by @hayescode (#2734)
标题: Chainlit < 2.9.4 Arbitrary File Read via /project/element | Advisories | VulnCheck -- 🔗来源链接
标签:third-party-advisory
神龙速读:
## 关键漏洞信息
### 漏洞标题
Chainlit < 2.9.4 Arbitrary File Read via /project/element
### 严重程度
HIGH
### 日期
January 19, 2026
### 受影响版本
- Chainlit < 2.9.4
### CVE与CWE
- CVE-2026-22218
- CWE-22 Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
### CVSS评分
5.3/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N
### 描述
Chainlit版本在2.9.4之前的版本存在一个任意文件读取漏洞,在/project/element更新流中。一个经过身份验证的客户端可以发送一个带有用户可控路径值的自定义元素,导致服务器将引用的文件复制到攻击者的会话中。所得的元素标识符(chainlitKey)然后可以用于通过/project/file/<chainlitKey>检索文件内容,允许披露任何可由Chainlit服务读取的文件。
### 参考
- Chainlit 2.9.4 Release Notes
### 致谢
Ido Shani and Gal Zaban of Zafran Security
暂无评论