Agent guardrails are a must. We are working on some solutions to solve this problem at 1Claw.
We are a reverse proxy with inspection. Would be curious if this would have caught it? :-)