By Kelsey Brown
Last month I said my habits came from the building site. The suspicion came from somewhere else.
There's a line on the front page of this site that says most people who build software have never broken into any. I wanted to explain it properly, because learning to break in is the most useful thing that ever happened to how I build.
The builder looks at a login form and pictures someone using it properly, with a name and a password and in they go. The attacker looks at the same form and only pictures someone using it wrong. What happens if I put something stupid in here? What if I just go round it? That's all a penetration test is, by the way, someone paid to be the second person before an unpaid one turns up.
Once you've looked at software from that side, you can't go back. I read my own code now like someone who wants to hurt it. It changes what finished means, too. A builder says it's finished when it works. An attacker wants to know what else it does, the things nobody meant it to do. Most of the ways in that I find are working features, doing exactly what they were built to do, for the wrong person.
It left me with three habits. I expose less, because every endpoint and every open port is one more thing to defend, so the first question is what can stay shut. I trust less. Nothing gets believed because of where it came from, since the browser lies and the admin account gets phished, so every part of the system checks for itself and never takes another part's word for it. And I build it so someone else can run it, because if a team can't run it and defend it without me, I haven't finished.
It works the other way too. Most people who break in never have to fix what they find. They write "fix your authentication" in a report and go home. Easy to write, miserable to receive. Because I build for a living, I know what a fix actually costs, and I know which ones can be done by Friday. So whatever I get into, I close.
It changes the report as well. A finding with no fix attached is homework for someone who's already busy. So mine come in the order I'd fix them, with the quick wins first, and the big one split into pieces a team can actually get through.
If you write software, spend a weekend trying to break your own project, or one you've got written permission to test. You'll write the next one differently.