Security and proper coding are different issues but they are closely related. Improper coding is a significant source of security vulnerabilities. Remember all of those memory overrun attacks that were so popular a few years back?.
There are many ways to detect improper coding - reading the code, team code reviews, lint checkers, and ... checks for undefined/mis-spelt variables, mismatches of parameter types. Computers are generally better than the human eye at catching those sorts of things, which is why we write syntax checkers and compilers with rich diagnostics. That feedback isn't just for newbies learning to code.
In Perl some of these can only be done at run-time because Perl is a loosely typed language and defines itself as it goes, but even with that limitation Perl does a fairly good job at the task if you use the warnings and strict pragmas.
Even very, very good coders can make dangerous typos.
Best, beth. |