제출 #1058778: eosphoros-ai DB-GPT 0.8.2 Path Traversal정보

제목eosphoros-ai DB-GPT 0.8.2 Path Traversal
설명DB-GPT 0.8.2 skill_upload path traversal (regression of CVE-2026-51862) Vendor: eosphoros-ai Product: DB-GPT Version: 0.8.2 Summary: DB-GPT 0.8.2 contains an unauthenticated arbitrary file write (path traversal, CWE-22) in the skill upload endpoint. The filename validation introduced in 0.8.1 (PR #3065, the fix for CVE-2026-51862) was removed in 0.8.2 by the multi-file upload refactor (PR #3206). An attacker can submit a multipart "file" part with a filename containing an absolute path or "../" sequences, and the server writes the uploaded bytes to that path outside the intended pilot/tmp upload directory. Affected code (packages/dbgpt-app/src/dbgpt_app/openapi/api_v1/agentic_data_api.py, skill_upload, 0.8.2): filename = file.filename tmp_file = upload_dir / filename tmp_file.write_bytes(content_bytes) The path is not validated. Python pathlib's "/" operator drops the left side for absolute paths and does not normalize ".." components. Proof of concept: curl -X POST http://<host>/api/v1/skills/upload \ -F '[email protected];filename=/tmp/backdoor.py' The file is written to /tmp/backdoor.py. Using filename="../../agentic_data_api.py" writes into the endpoint's own source tree. Authentication: The default get_user_from_headers returns a mock admin user (id="001"), so the endpoint is reachable without prior authentication. Timeline: - 0.8.0 (2026-03-27): vulnerable (raw file.filename) - PR #3065 (2026-05-21): added _validate_upload_filename() guard - 0.8.1 (2026-06-18): contains the fix (PyPI wheel verified) - PR #3206 (2026-08-21): multi-file upload refactor, guard removed - 0.8.2 (2026-08-26): VULNERABLE again (latest release) - PR #3270 (2026-09-28): re-fix on main, NOT yet released (no 0.8.3 on PyPI) This is a regression of CVE-2026-51862: the fix shipped in 0.8.1 was reverted in 0.8.2 and the corrected code exists only on the unreleased main branch. Solution: Re-add the _validate_upload_filename() guard (reject absolute paths, "..", backslashes, null bytes, symlinks) and release it as 0.8.3. Add a regression test. References: https://github.com/eosphoros-ai/DB-GPT/pull/3206 (regression commit) https://github.com/eosphoros-ai/DB-GPT/pull/3065 (original fix, CVE-2026-51862) https://github.com/eosphoros-ai/DB-GPT/pull/3270 (re-fix on main, unreleased) Full writeup: https://github.com/murongchengshu/zhicheng_tan/blob/main/DB-GPT_1.md
원천⚠️ https://github.com/murongchengshu/zhicheng_tan/blob/main/DB-GPT_1.md
사용자
 zhicheng_tan (UID 86956)
제출2026. 10. 27. AM 01:58 (29 날 ago)
모더레이션2026. 11. 25. AM 07:56 (29 days later)
상태수락
VulDB 항목443651 [eosphoros-ai DB-GPT 까지 0.8.2 Skill Upload agentic_data_api.py skill_upload filename 디렉토리 순회]
포인트들20

Do you want to use VulDB in your project?

Use the official API to access entries easily!