AG2 SandboxShellTool: files hidden with `ignore` are still readable through recursive `grep` / `diff` in readonly mode
- CVE-2026-141554
- GHSA-xhqj-2fcc-8vf7
- EUVD-2026-141826
Description
AG2 is an open-source AgentOS. From 0.13.3 until 1.3.4, SandboxShellTool configured with readonly=True and ignore can return ignored files when an allowed recursive grep, egrep, fgrep, or diff opens files inside a directory, including the implicit current directory. ShellAdapter._filter() in ag2/tools/sandbox/adapter/shell.py calls check_ignore() in ag2/tools/sandbox/filter.py, which checks paths written in the command but not files discovered by the program. An agent processing attacker-controlled content may issue such a command and expose the files in the tool result; disclosure to the attacker additionally requires an output channel in the deployment. This issue is fixed in version 1.3.4.
Text from the CVE.org record.
Recommendation
No source states a fixed version. Check the vendor advisory.
Affected
ag2ai ag2
Affected versions Fixed in >= 0.13.3, < 1.3.4 none stated ag2ai autogen
Affected versions Fixed in >= 0.13.3, <= 0.14.1 none stated ag2PyPI
Affected versions Fixed in from 0.13.3 up to 1.3.3 none stated autogenPyPI
Affected versions Fixed in from 0.13.3 up to 0.14.1 none stated
Product versions from the CVE.org record.
Timeline
- Published
Related news
No article from the followed outlets names this vulnerability.