Is it bad of me to have felt an acute rush of Schadenfreude over this?Millions of AI agents and tools around the world have been imperiled by a critical vulnerability that can allow hackers to breach the servers running them and make off with sensitive data and credentials to third-party accounts, a security researcher is warning.
Two things that are true:Starlette is the base of FastAPI and other widely used frameworks for building services in Python apps, as well as many others.
I'd put it as "Millions of AI agents and tools ARE a critical vulnerability..." but maybe that's just me.Millions of AI agents and tools around the world have been imperiled by a critical vulnerability...
I don't think "clearly must be", but at the same time "do the same basic thing two different ways within the same context for no obvious reason" is a thing that LLMs seem to routinely do.I'm going to poo poo people here in the comments going "Ah it clearly must have been vibe coded" was it? Starlet and FastAPI aren't old, but they aren't "spring chickens" ... A lot of MCPs that got built in the last 2 or 3 years probably pull in FastAPI just because it was ... well very fast to build REST APIs with it. Was the bug introduced by vibe coding or just pre-existing and a ton of REST APIs to control or serve tools and content for LLMs just happen to use it?
Fair. Is that what happened here? I think this is just a pre-existing, old-fashioned human made vuln, and its just a very popular package that provides the very necessary plumbing for basically any kind of MCP or even simple CRUD App integrated with an LLM. The relationship is casual, not causal.I don't think "clearly must be", but at the same time "do the same basic thing two different ways within the same context for no obvious reason" is a thing that LLMs seem to routinely do.
If so, then me too. I had a Nelson "Ha, ha" moment when I read the title. And it doubled down when I read the article. This DOES appear to be a very trivial to exploit, and should have been easy to discover before deployment, security hole.Is it bad of me to have felt an acute rush of Schadenfreude over this?
The times create a certain amount of deviation in my moral compass lately so it's a kind of relevant question. Because that rush was huge.
example.com into the host header, Starlette lets you also put things like example.com/abc?bar= in there, which turns a fetch of /foo from example.com into a fetch of http://example.com/abc?bar=/foo.Well, this is the essence of vibe coding - working as designed?
I don't think "clearly must be", but at the same time "do the same basic thing two different ways within the same context for no obvious reason" is a thing that LLMs seem to routinely do.
So I mean the criticisms is on Starlette then? Like not to anthropomorphize these things, because its cringe, but are you red teaming every package, especially popular packages, you're pip installing? I'm not going to go so far as to criticize Ars for editorializing the title a bit but this exact same vuln would have been bad regardless of whether a lot of AI tooling was built on top of it. If this happened in flask, which is very popular still, but seems to not be the framework most LLMs reach for to build a REST API or MCP, it would still be very bad.If so, then me too. I had a Nelson "Ha, ha" moment when I read the title. And it doubled down when I read the article. This DOES appear to be a very trivial to exploit, and should have been easy to discover before deployment, security hole.
I think if ars wants to avoid their own version of enshitification they should probably knock off the titles catering to the self proclaimed "luddite" tech poseur. It won't age well and it's sort of dishonest and agenda driven. In this case it's blatant reaching to everyone who has experience with these dependencies... And there are quite a few of us reading ars.I'm trying really hard to figure out why people think this vuln has anything to do with vibe coding or AI (aside from a lot of AI frameworks build on top of it — because it is simple and fast)
My website is written in FastAPI/Starlette (no auth, no problem). It's just a very popular framework.
And when we see evidence this is the result of that then it will be relevant, but that's not how this article was framed.Bad AI slop products are also from the same culture as the security-lax move-fast-and-break-things web development that created this bug though.
Fair enough, I stand corrected.From a quick look at the change made in the fixed version (1.0.1) and blame on the affected file, it looks like Starlette has been trusting the host header like this for 8 years - i.e. since it was first released.
As this article points out, it's one layer in the tech stack assuming that other layers are doing the right thing and not defensively coding.
Yup, move fast, break things and create huge security holes . . .
and the security-lax move-fast-and-data-mine the shit out of your customers automotive industry.Bad AI slop products are also from the same culture as the security-lax move-fast-and-break-things web development that created this bug though.
I'm trying really hard to figure out why people think this vuln has anything to do with vibe coding or AI (aside from a lot of AI frameworks build on top of it — because it is simple and fast)
My website is written in FastAPI/Starlette (no auth, no problem). It's just a very popular framework.
just ask the hackers, I mean, the researchers.Fair. Is that what happened here? I think this is just a pre-existing, old-fashioned human made vuln, and its just a very popular package that provides the very necessary plumbing for basically any kind of MCP or even simple CRUD App integrated with an LLM. The relationship is casual, not causal.
Remind me again why I bother reading security articles on ars instead of a mainstream newspaper? The quality seems to be converging, and not in the way I like.Starlette reconstructs request.url by concatenating the HTTP Host header with the request path and re-parsing the result. The Host value is not validated against the RFC 9112 / RFC 3986 grammar before reconstruction. A Host header containing /, ?, or # shifts the path, query, and fragment boundaries during re-parse, so request.url.path no longer matches the path the ASGI server actually received and routed against.