CVE-2026-28482: OpenClaw's unsanitized session ID enables path traversal in transcript file operations
OpenClaw built transcript file paths from an unsanitized `sessionId` and accepted `sessionFile` paths without checking that they stayed in the agent sessions directory. An authenticated gateway user could use a value like `../../etc/passwd` to read or write files outside it. Versions up to 2026.2.9 are affected. Upgrade to 2026.2.12.
Published Feb 18, 2026 · Updated Mar 6, 2026 · Analysis Oct 31, 2026
What an attacker can do
When the gateway reads or writes a session transcript, it joined the session ID into a filename and used the stored sessionFile as given. A crafted sessionId or sessionFile with path separators or .. sequences made those operations land outside the sessions directory (CWE-22). Read and write operations on transcripts are both involved, so the CVSS 4.0 vector rates confidentiality and integrity impact high.
The attacker must authenticate to the gateway with its token or password. The advisory notes that the gateway binds to loopback by default, which keeps this local. Configurations that expose the gateway widen the attack surface. A user with a valid but limited gateway credential can turn it into file access, bounded by the gateway process's permissions. For appending to a file, that can mean corrupting config or injecting content into files that other tools read.
The two CVSS scores differ. The 3.1 vector counts only confidentiality (5.5), while 4.0 counts both confidentiality and integrity (8.4).
Who is affected
The npm package openclaw at 2026.2.9 or earlier, per the advisory. The package data lists everything below 2026.2.12 as vulnerable, so treat 2026.2.10 and 2026.2.11 as unsafe as well. Check:
npm ls -g openclaw
openclaw --versionRisk is higher when the gateway listens on anything other than loopback.
openclaw
- Ecosystem
- npm
- Affected
- < 2026.2.12
- Fixed in
- 2026.2.12
- Check
npm ls openclaw
How to fix it
Upgrade to 2026.2.12, the patched version (commit 4199f98, extra hardening in cab0abf):
npm install -g [email protected]Session IDs are validated against a pattern of up to 128 characters, starting with a letter or digit and using letters, digits, dots, underscores and hyphens. Anything else throws "Invalid session ID". Session file paths must resolve inside the sessions directory or the call fails with "Session file path must be within sessions directory". The advisory lists no workaround other than upgrading. Keep the gateway on loopback and protect its token.
How to tell if you were hit
Look in gateway request logs for session IDs or session file values containing /, \ or ... Check the session store for entries whose sessionFile points outside the sessions directory. Look for transcript-style content appended to files outside that directory, and for modification times that match gateway requests. Review who holds gateway tokens, since the attack needs valid credentials.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Description
OpenClaw versions <= 2026.2.9 construct transcript file paths using an unsanitized sessionId and also accept sessionFile paths without enforcing that they stay within the agent sessions directory.
A crafted sessionId and/or sessionFile (example: ../../etc/passwd) can cause path traversal when the gateway performs transcript file read/write operations.
Preconditions: an attacker must be able to authenticate to the gateway (gateway token/password). By default the gateway binds to loopback (local-only); configurations that expose the gateway widen the attack surface.
Affected Packages / Versions
- Package:
openclaw(npm) - Affected:
<= 2026.2.9 - Fixed:
>= 2026.2.12
Fix
Fixed by validating session IDs (rejecting path separators / traversal sequences) and enforcing sessions-directory containment for session transcript file operations.
Fix Commit(s)
4199f9889f0c307b77096a229b9e085b8d856c26
Additional Hardening
cab0abf52ac91e12ea7a0cf04fff315cf0c94d64
Mitigation
Upgrade to openclaw >= 2026.2.12.
Thanks @akhmittra for reporting.
Credited to akhmittra.
Questions
- Can an unauthenticated user exploit CVE-2026-28482?
No. The attacker needs gateway authentication, a token or password. By default the gateway binds to loopback, so the attack is local unless you expose it.
- Which version fixes it?
2026.2.12. The advisory text says affected versions are 2026.2.9 and earlier, and the package data marks everything below 2026.2.12 as vulnerable.
- What does the fix check?
Session IDs must match a strict pattern with no separators or dots-only traversal, and session file paths must stay within the sessions directory.
- Is it exploited in the wild?
The sources do not report exploitation and it is not in CISA's KEV catalog.
References
Read for this analysis:
- https://github.com/openclaw/openclaw/security/advisories/GHSA-5xfq-5mr7-426q
- https://github.com/openclaw/openclaw/commit/4199f9889f0c307b77096a229b9e085b8d856c26
- https://github.com/openclaw/openclaw/releases/tag/v2026.2.12
- https://nvd.nist.gov/vuln/detail/CVE-2026-28482
- https://github.com/openclaw/openclaw/commit/cab0abf52ac91e12ea7a0cf04fff315cf0c94d64
- https://www.vulncheck.com/advisories/openclaw-path-traversal-via-unsanitized-sessionid-and-sessionfile-parameters
- https://github.com/advisories/GHSA-5xfq-5mr7-426q
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. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More OpenClaw vulnerabilities
All OpenClaw entriesCVE-2026-62197
OpenClaw: Browser CDP discovery could accept blocked WebSocket URLs
medium8.5Oct 21, 2026CVE-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, 2026
