Please enable JavaScript.
Coggle requires JavaScript to display documents.
data validation, Data sanitisation, Authentification, maintaibability,…
data validation
Types of checks
Range check- The input must fall within a certain range in order for it to be valid, this is usually applied to numbers and dates however can in some situation be used for characters. An example of range checking is when paying money to a bank. You only have a certain amount of money. ASo the range would be more than 0 but less than the amount you have.
Length check-the input must be a certain length or between. For example the username must be within 1-11 letters. username control would be invalid as its above 11. username would be fine as its between 1 and 11.
Presence check-This one is simple, it basically just checks to make sure something has been inputted. such as when placing an order for food saying how much you want
Format Check- The data must be entered in the correct format for example when asked for the dat. it must be wrote (days)/(month)/(year)
Type check- The data must be a certain data type- such as a quantity must be an integer. a decimal must be a real and a true or false should be a Boolean
-
Definition of data validation- Data validation is the rules for an input and if it follows the rules of the program or not. The data soudl be checked to be valid otherwise it may cause issues with the program
Data validation doesn't show that data is correct just that it is eligible and able to enter. A user may enter a birthday that is valid but because it does not match with the set up one it is invalid as a computer has no way to know what you've done is a mistake. The validation program will iterate(loop) until entry has been achieved or they have been locked out (authentication)
-
Data sanitisation
-
-
The purpose of data sanitisation is to hide the data and ensure that others cant gather or read it. input sanitisation checks the input and ensures that everything godo stays in and everyting back is removed.
Other types of data sanitisation is masking- This hides visible data by replacing it with something else. This works in the way of password. When showing a password often it will be covered by dots or * to make sure someone can't read it
Authentification
Types of authentication
Somethung you are- bankcard, email adress, anything that idenitfies yourself
Something you know- password, pin, security question
Something you have- card, biometrics, physical identification
-
This ones quite easy, this is the process of ensuring someone is what they say they are. Usually using passwords, emails and sometimes human features (biometrics)
Sometimes authentication can be bypassed by hacking or social engineering. Therefore some sites have thing such as two factor authentication which are two seperate emails and passwords which log an account in.
maintaibability
types of maintainability
Comments-these give a program easy to udnerstand messages that a normal (non coder) user could read as well. this fived indication of what certian parts of code could do and what their funtion actually is.
Sensible variable names- this makes gathering info a lot simpler and easier for a programmer. They can easily call a variable with a common name and its easy not to make mistakes with the code being entered. They also are easy to understand what their function may be
Indentation- This is used in python by colloms. It splits part of the code up into sections which will make it easier to understand which equation and functions do what. It also is easier to read which sequence will take place next. when indentation stops it indicated when a sequence of iteration stops running.
-
Maintainability is mainly used to ensure a server or website can be used easily without issues. Sometimes a manager or codder will have to return to the program to debug any issues that have been found.
-
-
-
-
-