Posts

Showing posts from May, 2026

Why AI-Generated Code Has Security Gaps That Look Like Clean Code

Image
The most dangerous bugs in software are the ones that are invisible during review. Code that looks well-structured, compiles cleanly, and handles common inputs correctly can still contain serious security vulnerabilities that only appear when someone specifically looks for them. AI-generated code has a higher frequency of this pattern than human-written code, for specific and understandable reasons. Understanding why helps teams know what to look for and where to invest testing effort. This is not an argument against using AI coding assistants. It is an argument for understanding their specific failure modes so you can address them systematically. Why AI-Generated Code Looks Secure When It Isn't When an AI model generates code, it draws from patterns learned across a large corpus of training examples. The code it produces reflects what is common in that corpus. Common patterns tend to be structurally correct: they follow language conventions, use appropriate data types, and hand...

Why Most Web Apps Get Access Control Wrong From Day One

Image
Access control is almost never the first thing a team builds. It's the thing they add when someone asks "wait, can any user see anyone else's data?" The answer, in a distressing number of cases, is yes. This isn't a criticism of developer skill. It's a critique of the development process. Access control failures aren't random. They follow predictable patterns that emerge from how authorization is approached at the start of a project. The "We'll Add It Later" Pattern The most common access control mistake is treating authorization as something to retrofit rather than design upfront. The reasoning is understandable: in the early stages of a product, you have a small team, a limited user base, and authorization complexity that seems manageable with a simple admin flag. That changes as the product grows. More user types appear. Different users need different access. The simple admin flag becomes a set of overlapping conditionals. By the time ...