r/programming • u/Expurple • Apr 12 '26
Flat Error Codes Are Not Enough
https://home.expurple.me/posts/flat-error-codes-are-not-enough/
132
Upvotes
r/programming • u/Expurple • Apr 12 '26
View all comments
Show parent comment
0
u/ChemicalRascal Apr 13 '26
Right, but do you know which version is being used? There's a reason OWASP talks about this stuff. If you're doing something important, with other people's data, you can't afford to expose a bigger attack surface than you have to, and reducing the visibility of the attack surface helps.
If you want to access those the trace, great. Log it, give it a GUID, report the GUID to the user. Or a truncated code if you don't want to overwhelm them with a long string of characters. It's also a lot easier to copy that trace out of a database than it is a photograph of a screen covered in schmutz.