Invoice tracker teardown: the code behind https://getainative.com/ai-built-app-teardown-before-and-after/ before/server.js the app as an AI coding tool tends to write it (76 lines) after/server.js the same app after the engineering review security.test.js nine checks that run against either version exploit.sh the six attacks from the post, run by hand with curl Run it (Node 22 or newer): npm install npm run test:before # 8 of 9 fail npm run test:after # 9 of 9 pass To try the attacks by hand: cd before && node server.js # in one terminal, with no invoices.db around ./exploit.sh # in another This is a demo app written for the post. It is not a real product and not code from a real customer. Do not deploy it.