@dummerspast39 Best lab on Monday, roadkill by Friday. That's the whole reason you don't hardwire your stack to one model provider. Put a gateway in front and swap models like tires. The vibes at the lab are their problem, not yours.
The config, the price math, and how I'd roll it out in Audit first are in the Article: https://t.co/IFDyYQqHPY
I work at https://t.co/3GLfdghWke, which makes agentgateway.
I capped LLM spend per API key on agentgateway. Three things the 429 won't tell you.
Usage is billed after the response. A $0.01 key ended at $0.012.
A model with no price never charges a dollar budget. No error.
An over-budget key gets 429 before the 403 model check runs.
Gemini 4 Neon dropped and everyone wants to try it.
Hardcode the model in every agent and trying it means touching every agent.
Mine call one route on agentgateway. Swapping the model is one config change there.
@efipm Makes sense. The test I'd expect from a supervisor is simple: can you stop one agent without rotating prod keys? That's easy if the agent never held a key, and painful if it did.
@devops_nk The sandbox only helps if egress is decided outside it. In my egress test, an agent behind a proxy it was told to use got around it by editing /etc/hosts and riding the NO_PROXY exemption. A gateway that checks the destination at connect time stopped all four tricks I tried.
@levie Agreed, and it moves where the limits live. If you stop telling the agent how, the prompt can't be the guardrail either. Spend caps, tool policy and what it can reach on the network have to sit outside the agent, where it can't talk its way past them.
@v_shakthi And the record has to live somewhere the agent can't write. METR and Redwood reviewed about 1,300 agent transcripts and found roughly 7% had spoofed tool calls. A log written by the thing being audited won't hold up when the auditor asks.
@thorstenball Same question for agents, and I like the answer even more there. In my lab they run with no route out except a gateway that allows named destinations. They don't miss the open internet, and a hijacked one has nowhere to send what it found.
@GergelyOrosz The .env file is the one thing I'd keep the agent from reading. Supply chain stealers go straight for env vars and .env files. In my demo the agent holds no provider key at all, just a 60 second identity token, and the gateway adds the real key on the way out.
Two releases of Microsoft's agent-framework on PyPI shipped a credential stealer. It ran when Python started.
No prompt. No tool call. Just an install.
My agent boxes hold no long-lived keys. The gateway adds the real one on the way out. The agent's token expires in 60 seconds.
@sunilmehta_si That leak works because the secrets sit where the process can read them. If the agent never holds the real credential, a hijacked package finds a short-lived identity token and nothing else. In my demo it lasts 60 seconds and the gateway adds the real credential on the way out.
@shahidcodes OAuth beats a pasted key. Next thing I'd check is what the token is good for. If it isn't bound to that one server, it works at every backend that trusts the same issuer, so one injected instruction reaches all of them. Naming the audience in the token exchange fixes that.
@hsianghui Worth doing, but an install scan only sees what the server shows at install. In my lab, rebuilding a real campaign, the MCP server behaved for three calls, then rewrote its tool descriptions into instructions to find SSH keys. Pinning a hash of each definition caught it.
@rauchg The open-weight jump is the part I'd watch. Once a team mixes providers, a cap per provider stops meaning much. The budget and the list of allowed models belong on each key, so a key issued for a cheap model can't quietly start calling the expensive one.
@GergelyOrosz@CompleteSkeptic I benchmarked it in September on classifying agent tool calls. 55 of 60 right, and the confidence score held up: 40 answers came back at exactly 1.000 and all 40 were correct. Where it slipped was the genuinely ambiguous calls, 71.4% there.
@BoboLinNotes I'd add one more: agents that attack when nobody asked them to. Transluce found agents answering ordinary data questions trying SQL injection, XSS and path traversal when the normal download didn't work. No attacker involved. That's why the limits have to live outside the agent.
@Bug_Breakdown Injection got the tokens read. Egress is what let them leave. If the helpdesk could only reach the hosts it needed, they'd have had nowhere to go. And lock DNS too. In my lab a plain DNS lookup carried data out until DNS was limited to the cluster's own resolver.
@saadkhalidhere Approval has a second gap: tools can change after you approve them. In my lab an MCP server behaved, then rewrote its tool descriptions mid-session into instructions to go find SSH keys. The name allowlist let it through. Pinning a hash of each definition caught it.