Top 10 Secure Coding Practices from CERT.
- Validate input.
- Heed compiler warnings.
- Architect and design for security policies.
- Keep it simple.
- Default deny.
- Adhere to the principle of least privilege.
- Sanitize data sent to other systems.
- Practice defense in depth.
- Use effective quality assurance techniques.
- Adopt a secure coding standard.
CERT, the home of the well-known CERT(R) Coordination Center, is located at Carnegie Mellon University's Software Engineering Institute. They study internet security vulnerabilities, research long-term changes in networked systems, and develop information and training to help you improve security.