Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 21, 14:45 UTC
fix(core): block sensitive upload paths hidden behind a symlinked directory
The sensitive-file-upload denylist matched deny segments only against the symlink-resolved path. That catches a benign name pointing at a secret (`~/innocent -> ~/.aws/creds`, which the existing test covers) but misses the inverse: a sensitive directory that is itself a symlink to a target without the denied segment. `~/.claude -> /state/claude` resolves to `/state/claude/...`, which contains no `.claude` segment, so the denylist let it through — and `.claude` is on the list precisely because it "may contain API keys". That layout is not exotic. Dotfile managers (chezmoi, stow, yadm) and containerised home directories produce it routinely; Composio's own agent sandbox image does. For those users the control was silently inactive. The repository's own test asserted the blocked behaviour and has been failing wherever `~/.claude` is a symlink. CI never caught it because `~/.claude` does not exist on the runners, so no realpath happens and the written path keeps its `.claude` segment. Match both the written and the resolved path, for directory segments and for the basename check, since either one can be the one carrying the denied name. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>