CVE-2026-88624 Overview
CVE-2026-88624 is a path traversal vulnerability in openCode v1.18.26. The flaw resides in the Worktree.remove component, which fails to validate file paths before performing deletion operations. Attackers can submit a crafted payload that triggers recursive directory deletion outside the intended worktree boundary. The weakness is classified under [CWE-22] (Improper Limitation of a Pathname to a Restricted Directory). Exploitation requires no authentication, no user interaction, and can be executed over the network. Successful attacks compromise integrity and availability by destroying arbitrary directories accessible to the process.
Critical Impact
Remote, unauthenticated attackers can trigger recursive directory deletion across the file system, causing data loss and service disruption.
Affected Products
- openCode v1.18.26
- Deployments exposing the Worktree.remove component to network input
- Downstream integrations invoking the vulnerable removal API
Discovery Timeline
- 2026-09-22 - CVE-2026-88624 published to the National Vulnerability Database (NVD)
- 2026-09-23 - Last updated in NVD database
- 2026-09-24 - EPSS score published at 0.345%
Technical Details for CVE-2026-88624
Vulnerability Analysis
The vulnerability exists in the Worktree.remove function of openCode v1.18.26. The function accepts a path parameter and performs a recursive deletion operation without validating that the target resides within the expected worktree directory. Attackers can supply relative traversal sequences or absolute paths to escape the intended boundary. Because the delete operation is recursive, a single crafted request can remove entire directory trees. The result is loss of application state, configuration files, or user data depending on the privileges of the openCode process.
Root Cause
The root cause is missing path canonicalization and boundary enforcement in the Worktree.remove handler. The component trusts caller-supplied path input and passes it directly to a recursive filesystem deletion routine. Neither prefix validation against the worktree root nor rejection of .. traversal sequences is performed. This aligns with [CWE-22], where user-controlled path input reaches a sensitive filesystem operation without sanitization.
Attack Vector
Exploitation occurs over the network without authentication or user interaction. An attacker sends a crafted request to the vulnerable openCode endpoint with a path parameter containing directory traversal segments or an absolute path pointing outside the worktree. The server processes the request and recursively deletes the referenced directory. See the GitHub Issue Report for reproduction details.
No verified exploitation code is published in the enriched data. Refer to the linked issue report for technical reproduction context.
Detection Methods for CVE-2026-88624
Indicators of Compromise
- Unexpected recursive deletion events on directories outside the openCode worktree root
- HTTP or API requests to Worktree.remove containing .., absolute paths, or encoded traversal sequences such as %2e%2e%2f
- Sudden absence of configuration, log, or data directories accessed by the openCode service account
Detection Strategies
- Inspect application and reverse proxy logs for requests targeting the Worktree.remove endpoint with anomalous path parameters
- Correlate filesystem audit events (Linux auditd, Windows object access) with process activity from the openCode binary
- Alert on unlink or rmdir syscalls issued by the openCode process against paths outside its designated working directory
Monitoring Recommendations
- Enable filesystem integrity monitoring on directories adjacent to the openCode worktree
- Forward openCode application logs to a centralized SIEM for path-parameter anomaly detection
- Establish baselines for normal Worktree.remove invocations and alert on deviations in path structure or volume
How to Mitigate CVE-2026-88624
Immediate Actions Required
- Restrict network exposure of openCode v1.18.26 instances until a patched release is available
- Run the openCode process under a least-privileged account that cannot access sensitive directories
- Place the service behind an authenticated reverse proxy that rejects path parameters containing traversal sequences
Patch Information
No vendor patch reference is included in the enriched CVE data. Monitor the upstream openCode repository and the GitHub Issue Report for fix availability. Upgrade to any release later than v1.18.26 that documents path validation in Worktree.remove.
Workarounds
- Deploy a web application firewall rule that blocks requests to Worktree.remove containing .., %2e%2e, or absolute path prefixes
- Enforce filesystem-level access controls that restrict the openCode process to its worktree directory
- Isolate openCode within a container or chroot environment to limit the blast radius of unauthorized deletions
# Example WAF rule (ModSecurity) blocking traversal in Worktree.remove requests
SecRule REQUEST_URI "@contains Worktree.remove" \
"chain,deny,status:400,id:1026886240,msg:'CVE-2026-88624 path traversal attempt'"
SecRule ARGS "@rx (\.\./|%2e%2e%2f|^/)" "t:lowercase,t:urlDecodeUni"
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.