/

CVE-2026-100559

Severity:

HIGH RISK

(8.0)

OS Command Injection (CWE-78) in OpenClaw Exec Parser

CVE-2026-100559

Deferred

Vulnerability type

Category:

OS Command Injection

CWE:

CWE-78

Impact:

Unauthorized Command Execution

Severity:

HIGH RISK

(8.0)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

OpenClaw has a command parser vulnerability in which escaped newlines can confuse execution allowlist checks. An attacker who can submit crafted command input may bypass expected authorization prompts and cause additional commands to execute.

Affected context

The vulnerability occurs in OpenClaw command execution paths that parse user-controlled or otherwise untrusted input through an execution allowlist. It becomes risky when escaped newline handling differs between validation and execution, allowing hidden command segments to evade authorization checks.

Exploit preconditions

  • Attack surface: OpenClaw command parsing and execution functionality
  • Required access: Ability to submit or influence input processed by the command executor
  • Trigger point: Parsing and validation of command strings containing escaped newline characters
  • Why exploitation is possible: The allowlist parser may interpret the input differently from the later execution path, allowing additional command content to bypass expected authorization controls

Why this happens

The underlying issue is inconsistent parsing of command input across validation and execution stages. Escaped newline characters can alter command boundaries or hide additional command segments from an allowlist, mapping to CWE-78: Improper Neutralization of Special Elements used in an OS Command. The insecure pattern is treating a command string as safely validated when the parser and executor do not apply identical, canonicalized interpretations.

Potential impact

  • An attacker may execute commands outside the approved allowlist
  • Unauthorized commands could modify application or host state
  • Sensitive data may be accessed or altered
  • The affected runtime could be used for lateral movement or persistence
  • Security prompts and operator approval workflows could be bypassed

General mitigation guidance

Mitigation generally focuses on eliminating ambiguous command-string parsing and reducing the amount of input that reaches an operating-system shell.

Common defensive patterns include:

  • Prefer structured process APIs with fixed executables and argument arrays over shell command construction
  • Canonicalize and validate input using the same representation consumed by the execution layer
  • Reject control characters, escaped newlines, and unexpected command separators by default
  • Use explicit allowlists for executables and separately validate each argument
  • Avoid deriving authorization decisions from display-oriented or partially parsed command text
  • Run command-executing components with least privilege and constrained filesystem and network access
  • Require explicit authorization for commands that fall outside narrowly defined capabilities

How teams detect issues like this

Organizations can look for:

  • Static analysis findings involving shell invocation, string-based command construction, or inconsistent command normalization
  • Code review signals such as allowlist checks performed before a separate parser or executor interprets the same input
  • Tests covering escaped newlines, control characters, quoting, separators, and alternate command representations
  • Runtime logging that records canonicalized command intent, authorization decisions, and execution outcomes without exposing sensitive data
  • Policy enforcement that restricts shell access and requires structured process execution
  • Automated security review tools configured to identify command injection and parser differential patterns

Sources

SourceLink
github.comgithub.com/openclaw/openclaw/security/advisories/GHSA-9f86-pvv5-rxfw
vulncheck.comvulncheck.com/advisories/openclaw-before-2026.8.1-command-injection-via-escaped-newlines

Frequently asked

questions

It may be exploitable remotely when OpenClaw exposes command execution through a network-accessible interface and an attacker can submit command input. In local deployments, the attacker would generally need access to an equivalent input path.

Authentication requirements depend on the surrounding OpenClaw deployment. The essential condition is the ability to influence input processed by the vulnerable command parser; authorization controls may be weakened by the parsing discrepancy.

Use structured, non-shell process execution with fixed executable and argument boundaries, and ensure validation operates on the same canonical representation that will be executed.

Test parser and executor behavior with control characters and alternate encodings, reject ambiguous command syntax by default, enforce least privilege, and require security review for command-execution features.

Find out what's already
exploitable in your codebase.