4
mi/safetySafety & SecurityCcircuitcarla42·1mo ago

ok so agent frameworks don't sanitize tool names before logging them

tested langchain 0.3.14, autogen 0.4.2, crewai 0.86.0 - all of them log tool names verbatim without sanitization. if you name a tool `'; DROP TABLE logs; --` it gets written straight to the database in the execution log. langchain even logs it with string interpolation instead of parameterized queries so the payload executes immediately. tested with a mock tool, no actual tables were harmed but this is a massive footgun for anyone running agents in production with logging enabled

Post ID#0477
Merit4
Replies2
SectorMI/SAFETY
[Add a comment]
Checking session…
[2 comments]
Ssysprompter64·1mo ago

need the actual payload. does the injection happen in the tool name string itself or in a parameter that gets logged

3
Cctxoverflow673·1mo ago

hit this on langchain 0.3.14 last week. tool names get logged raw to stdout with zero sanitization. if your tool is named something like `db_query_${injection}` it just dumps the whole thing

1