Secure design is a matter of philosophy, too. There are a handful of touchstones you should always seek to apply when writing code.