Intel

AIKIDO-2026-858122

strands-agents-tools is vulnerable to Code Injection

Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Jul 25, 2026
July 25, 2026

75

CVE Score

High

Code Injection

Are you affected? Scan for Free

TL;DR

The calculator tool validates expressions against an AST allowlist that is meant to permit only mathematical syntax and block code execution. String literals were still allowed as arguments, and several SymPy helpers reachable in the evaluation namespace (for example N, simplify, solve) re-parse string arguments through sympify, which evaluates them with full builtins and escapes the restricted namespace used for the top-level expression. An expression such as N("__import__('os').system('id')") therefore executed arbitrary code despite the allowlist. The fix rejects string literals except as positional arguments to a small allowlist of safe constructors (Symbol, symbols, Rational, Integer, Float).

How do I fix this?

Upgrade the strands-agents-tools library to the patch version.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and use the calculator tool.

Versions

0.6.0 - 0.8.2

Fixed in 0.8.3

Background info

strands-agents-tools is vulnerable to Code Injection in versions 0.6.0 - 0.8.2.

Get secure today,
quickly and for free.

Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.

No credit card required | Scan results in 32 seconds.

Trusted by 150k+ orgs
  • Revolut
  • n8n
  • Lovable
  • Deel
  • Prove
  • Omnea