Skip to main content
← Vulnerabilities

AG2: Newline injection in SandboxShellTool bypasses allowed=[...] and readonly=True, enabling arbitrary command execution

8.8HighCNA
Exploited
No known exploitation
Fix
Fixed in 1.1.1
Who is exposed
Not reported

Do first: Upgrade to a fixed version: 1.1.1.

Published
Last modified
12/100 · provisional
None on Exploit-DB, Metasploit or GitHub

Summary

AG2, an open-source agent framework, has a flaw in its SandboxShellTool where a newline or carriage-return character can slip past the command filter that enforces allowed=[...] and readonly=True. An attacker who can influence the agent's command over the network, with low privileges and no user action, can run arbitrary commands with the privileges of the agent process, which can compromise confidentiality, integrity, and availability.

Written by anthropic/claude-haiku-5.5 from the sources below. Verify against them.

Read the original description

AG2 is an open-source AgentOS. From 0.13.2 until ag2 1.1.1, and from autogen 0.13.2 to 0.14.1, SandboxShellTool configurations using allowed=[...] or readonly=True rely on ShellAdapter._filter and contains_shell_operator in ag2/tools/sandbox/filter.py and ag2/tools/sandbox/adapter/shell.py to validate a command prefix and reject selected shell syntax. The filter omits newline and carriage-return separators, while the accepted raw string is passed to sh -c, allowing an attacker-influenced agent command to execute an additional arbitrary statement. With the default LocalEnvironment backend, the injected statement runs as a host subprocess with the privileges of the agent process and can affect confidentiality, integrity, and availability. This issue is fixed in ag2 version 1.1.1.

cve.now Index

12Pcve.now Index 12 of 100 · methodology v3 · provisional
  • Exploitation?/40Unknown. No CISA SSVC exploitation rating yet
  • Exposure3/25Reachable over the network · Unknown: No advisory context yet
  • Reach?/20Unknown. No tracked technology or package matched
  • Severity8.8/10CVSS 8.8
  • No patch0/5No signal

What would change the score

  • Would score about 67 if added to CISA KEV
  • Would score about 62 if CISA's SSVC rates exploitation active
  • Would score about 31 if advisories confirm default setups are exposed

What to do

  • Upgrade to a fixed version: 1.1.1.

Timeline

  1. CVE published
  2. First seen by cve.now

Affected versions

  • ag2ai ag2

    From 0.13.2 · fixed in 1.1.1

  • ag2ai autogen

    From 0.13.2 · through 0.14.1

Evidence 3

  1. Advisory
  2. Repository
  3. Repository

Corrections

None so far.

Something wrong on this page? Report an error. Every fix is listed here.

Questions about CVE-2026-113663

Is CVE-2026-113663 being exploited?

It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.Source: cve.now feed data

Which versions are affected by CVE-2026-113663?

ag2: from 0.13.2 before 1.1.1. autogen: from 0.13.2 through 0.14.1.Source: cve.now feed data

How do I fix CVE-2026-113663?

Upgrade to a fixed version: 1.1.1.Source: cve.now feed data