2.3.1 Defensive design Flashcards
What does anticipating misuse include?
Users tyring to access parts of the program they should not
Users intentionally trying to break or crash a system
Accidental misuse and key presses
How can authentication be checked?
Use of passwords to prevent unauthorised access
Specific uses can be given limited functionality
Additional security questions can be asked
How can we check input validation?
Comparing against defined responses
Allowing only specific data types
Is the data entered outside of an expected range?
How do you keep a program well maintained?
Comments
Indentation
Naming conventions
Sub-programs
What are comments?
Programmer notes to describe functionality
What is indentation?
seperates statements into groups and highlights features
What is naming conventions?
Ensuring variable names are sensible and purposeful, such as firstName or productCode
What are sub-programs?
use these to avoid repetition and when they will benefit the program