CVE-2026-31994: Openclaw OpenClaw Windows Scheduled Task Script Vulnerability
HIGHCVE-2026-31994 is a HIGH openclaw windows scheduled task script vulnerability (CWE-116: Improper Encoding or Escaping of Output) affecting Openclaw libraries in the npm ecosystem. The issue involves openclaw windows scheduled task script generation allowed local command injection via unsafe cmd argument handling. Remediation is available by upgrading affected packages to version 2026.2.19.
CVE-2026-31994 at a Glance
How to Fix CVE-2026-31994
To remediate this vulnerability, upgrade all affected Openclaw dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install openclaw@2026.2.19
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls openclaw
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2026-31994, inspect your project dependencies using npm:
npm ls openclaw
Analyze the terminal output to locate any version of Openclaw in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2026.2.19), your application is affected.
Note: The npm ls openclaw command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-116: Improper Encoding or Escaping of Output, where the product prepares a structured message for communication with another component, but encoding or escaping of the data is either missing or done incorrectly. as a result, the intended structure of the message is not preserved. In Openclaw, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-31994 Affected Openclaw Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
openclaw
|
npm |
< 2026.2.19
|
2026.2.19
|
References
Frequently Asked Questions
What is CVE-2026-31994?
Which Openclaw versions are affected?
What version fixes CVE-2026-31994?
Is openclaw affected?
What CWE is associated with CVE-2026-31994?
How can I check npm dependencies for CVE-2026-31994?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-mqr9-vqhq-3jxw",
"modified" : "2026-03-19T21:24:33Z",
"published" : "2026-03-03T21:37:29Z",
"aliases" : [ "CVE-2026-31994" ],
"summary" : "OpenClaw Windows Scheduled Task script generation allowed local command injection via unsafe cmd argument handling",
"details" : "### Summary\nOpenClaw Windows Scheduled Task script generation allowed unsafe argument handling in generated `gateway.cmd` files. In vulnerable versions, cmd metacharacter-only values could be emitted without safe quoting/escaping, which could lead to unintended command execution when the scheduled task runs.\n\n### Details\nThe issue affected Windows daemon startup script generation in `src/daemon/schtasks.ts`.\n\nVulnerable behavior included:\n- Incomplete cmd argument quoting for metacharacter-only values.\n- Incomplete handling of cmd expansion-sensitive characters in script arguments.\n- Missing CR/LF guards for script-rendered fields.\n\nThe fix hardens Windows script generation by:\n- Separating schtasks argument quoting from batch script argument quoting.\n- Quoting cmd metacharacter arguments and escaping `%` / `!` expansion cases.\n- Rejecting CR/LF in command arguments, task descriptions, and rendered environment assignments.\n- Adding regression tests for metacharacter and line-break injection paths.\n\n### Impact\nThis issue is local to Windows deployments and requires control over values that feed service script generation (for example install-time/runtime arguments or environment-derived values). It can result in unintended command execution in the scheduled task context.\n\n### Affected Packages / Versions\n- Package: `openclaw` (npm)\n- Vulnerable versions: `<= 2026.2.17`\n- Patched version: `>= 2026.2.19` (planned next npm release)\n- Latest published npm version at update time (2026-02-19): `2026.2.17`\n\n### Fix Commit(s)\n- `280c6b117b2f0e24f398e5219048cd4cc3b82396`\n\nOpenClaw thanks @tdjackey for reporting.",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "openclaw"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2026.2.19"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/openclaw/openclaw/security/advisories/GHSA-mqr9-vqhq-3jxw"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-31994"
}, {
"type" : "WEB",
"url" : "https://github.com/openclaw/openclaw/commit/280c6b117b2f0e24f398e5219048cd4cc3b82396"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/openclaw/openclaw"
}, {
"type" : "WEB",
"url" : "https://www.vulncheck.com/advisories/openclaw-local-command-injection-via-unsafe-cmd-argument-handling-in-windows-scheduled-task"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-116" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2026-03-03T21:37:29Z",
"nvd_published_at" : null
}
}