CVE-2026-22171: OpenClaw vulnerable to path traversal in Feishu media temp-file naming allows writes outside os.tmpdir()
Summary OpenClaw’s Feishu media download flow used untrusted Feishu media keys (imageKey / fileKey) when building temporary file paths in extensions/feishu/src/media.ts. Because those keys were interpolated directly into temp-file paths, traversal segments could escape the temp directory and redirect writes outside os.tmpdir().
Published Mar 3, 2026 · Updated Mar 19, 2026
Affected packages
openclaw
- Ecosystem
- npm
- Affected
- < 2026.2.19
- Fixed in
- 2026.2.19
- Check
npm ls openclaw
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Summary
OpenClaw’s Feishu media download flow used untrusted Feishu media keys (imageKey / fileKey) when building temporary file paths in extensions/feishu/src/media.ts. Because those keys were interpolated directly into temp-file paths, traversal segments could escape the temp directory and redirect writes outside os.tmpdir().
Impact
This is an arbitrary file write issue (within the OpenClaw process file permissions). If an attacker can control Feishu media key values returned to the client (for example via compromised upstream response path), they can influence where downloaded bytes are written.
Affected Packages / Versions
- Package:
openclaw(npm) - Latest published npm version at triage:
2026.2.17 - Affected versions:
<= 2026.2.17 - Fixed version:
2026.2.19
Fix Commit(s)
c821099157a9767d4df208c6b12f214946507871cdb00fe2428000e7a08f9b7848784a0049176705ec232a9e2dff60f0e3d7e827a7c868db5254473f
Remediation
The fix removes key-derived temp-file naming and keeps downloads in safe temp locations. Additional hardening isolates SDK writeFile calls in per-download temp directories (mkdtemp) with deterministic cleanup, enforces Feishu key trust-boundary validation, and adds a repository guard test against dynamic path.join(os.tmpdir(), \...${...}\) patterns in runtime code.
OpenClaw thanks @allsmog for reporting.
Credited to allsmog.
References
- https://github.com/openclaw/openclaw/security/advisories/GHSA-vj3g-5px3-gr46
- https://github.com/openclaw/openclaw/commit/c821099157a9767d4df208c6b12f214946507871
- https://github.com/openclaw/openclaw/commit/cdb00fe2428000e7a08f9b7848784a0049176705
- https://github.com/openclaw/openclaw/commit/ec232a9e2dff60f0e3d7e827a7c868db5254473f
- https://nvd.nist.gov/vuln/detail/CVE-2026-22171
- https://www.vulncheck.com/advisories/openclaw-path-traversal-in-feishu-media-temporary-file-naming
- https://github.com/advisories/GHSA-vj3g-5px3-gr46
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
More OpenClaw vulnerabilities
All OpenClaw entriesCVE-2026-35630
OpenClaw: QQBot native approval buttons did not enforce configured approver identity
high8.0Jul 2, 2026CVE-2026-53806
OpenClaw: Combined POSIX shell options could confuse exec revalidation
high8.8Jul 2, 2026CVE-2026-53809
OpenClaw: Embedded runner policy could be confused by provider aliases
medium3.8Jul 2, 2026CVE-2026-53810
OpenClaw's marketplace runtime extension metadata could point at unscanned payloads
high8.8Jul 2, 2026CVE-2026-53811
OpenClaw: Matrix allowFrom could bind to mutable display names
high8.8Jul 2, 2026CVE-2026-53812
OpenClaw's browser act interactions could bypass private-network navigation checks
medium7.7Jul 2, 2026
