Computer-Science-IGCSE-notes
Computer-Science-IGCSE-notes
Binary
- Based on 2
- Made up of 1s and 0s
Uses of binary:
1. A register of bits 10010111
2. Robotics e.g. 1 = on, 0 = off for motor
3. Digital instruments
4. Counting systems
Measurements:
Binary Denary
a base-2 system a base-10 system
uses 0 and 1 values uses 0 to 9 values
has units/ placeholders/column headings that increase has units/ placeholders/column headings that increase
by the power of 2 by the power of 10
has more digit for the same value has less digits for the same value
e.g. explain the process of converting the binary number 1010 into a denary number
Hexadecimal
- Base 16
- Numbers 1-9 and letters A-F used
• Easier to debug
Colours in HTML:
Hex can be used to represent colours on web pages and image-editing programs using the format #RRGGBB (RR =
reds, GG = greens, BB = blues). The # symbol indicates that the number has been written in hex format. Different
combinations in hex codes will create different shades/tones/colours.
MAC Addresses:
Made up of 6 pairs of hexadecimal digits, the first half is the identity number of the manufacturer of the device and
second half is the serial number of the device. Universally Administered MAC Adress (UAA) most common or Locally
Administered MAC address (LAA).
Using hexadecimal makes it easier, faster, less error prone to write code compared to binary because it can
represent 16 bit words as only 4 hexadecimal digits, and it is easy to convert hex digits back to binary if necessary.
Debugging:
Memory Dumps: Hexadecimal is used when developing new software or when trying to trace errors. The hex
number refers to the memory location of the error. This helps programmers to find and then fix problems. Memory
dump is when the memory contents are output to a printer, monitor.
Web Addresses:
Half-duplex Data transmission sent in both directions but not at the same time
Full-duplex Data transmission sent in both directions at the same time. (can be
serial/parallel, not always used to connect a device to a computer, does not
automatically detect errors in data)
Serial data transmission When data is sent, one bit at a time, over a single wire or channel
Parallel data transmission When several bits of data, usually a byte, is sent down multiple wires or
channels at the same time.
Advantages:
Disadvantages:
Example of use
Usually used only on short distances because over long distances the data will skew and ‘merge’ between the two
wires or channels.
Disadvantages:
- Only supports short distances (becomes skewed over long distance – bits travel at different speeds)
- More chance of data being skewed due to bits being sent simultaneously/out of order
- More expensive as requires several/multiple wires
Example of use
o Integrated circuit because data is transmitted over a short distance and there is no risk of skewing of
data.
o Integrated circuits – parallel transmission, for sending data internally
o RAM
o Connections to peripheral devices
You need to check for errors because data is easy to corrupt/skew. You also don’t want wrong data.
Simplex Examples:
• Microphone to computer
• Sensor to computer
• Computer to printer
• Computer to speaker
• Computer to monitor
• Webcam to computer
• Sending data to a device // sending data from a device
- Voice over IP
- Computer to printer (only award once)
- Instant messaging
- Broadband connections
- Video conferencing
- Sending data to and from devices e.g wireless technology
- Computer to modem
- -> will allow read and write at the same time
Parity bits
USB
- Asynchronous serial
- Four wire shielded cable
- Two wires for power and earth
- Two wires for data transmission
Three things that happen when a device is plugged into a USB port:
• The computer automatically detects that a device is present(this is due to a small change in voltage level on
the data signal in the cable)
• The device is automatically recognised, and the appropriate device driver is loaded up so that the computer
and device can communicate effectively.
• If a new device is detected, the computer will look for the device driver which matches the device; if this is
not available, the user is prompted to download the appropriate software.
Advantages Disadvantages
• Store favourites
• Store history
• Check security
• Allows a homepage
e.g. students use a web browser to access the web pages. Explain the role of a browser in this process
• Sends the URL of the website • … to a DNS to find the IP address • Connects to the webserver (using the IP
address) … • … using HTTP / HTTPS • Renders/Translates the HTML • Runs active/client-side scripts built into
webpages • Manages SSL/TLS certificate process • Stores/retrieves cookies
When a user accesses a website:
Requested
Sent
Received
Companies that provide the user with access to the internet and other services such as web hosting and emails,
usually in a monthly fee.
HTML
Hypertext mark-up language used to create/develop/author webpages. It is translated by a browser to display
webpages and uses (opening and closing) tags to display/format content.
Structure:
Instructs how the layout of the content is displayed – layout of the webpage, defined using tags, e.g. where a
paragraph is placed, placing an image alongside some text
Presentation:
instructs how the content will be formatted e.g. colour/style/CSS, the colour that is applied to some text
Security on browsers
HTTP and HTTPS
HTTP and HTTPS (Hypertext Transfer Protocol) governs communication between a web server and a client. HTTPS
(secure) includes secure encryption to allow transactions to be made over the internet.
• Uses encryption
SSL
- the web browser attempts to connect to a web site which is secured by SSL
- the web browser requests the web server to identify itself
- the web server sends the web browser a copy of its SSL certificate
- the web browser checks whether the SSL certificate is trustworthy; if it is then the web browser sends a
message back to the web server
- the web server will then send back some form of acknowledgement to allow the SSL encrypted session to
begin
- the encrypted data is then shared securely between the web browser and the web server
MAC address:
Hardware identification number that uniquely identifies each device on a network; it is manufactured into every
network card and cannot be altered.
It refers to the network interface card (NIC) which is part of the device
Made up of 48 bits and 6 groups of hexadecimal digits, the first half is the identity number of the manufacturer of
the device and second half is the serial number of the device
- Universally Administrated MAC Address (UAA), UAA is the most common type set by the manufacturer
- Locally Administrated MAC Address (LAA)
IP address:
Internet protocol address, a location of a given computer/device on a network; can be a static or dynamic value.
Consists of four sets of up to three digits, each with a maximum value of 255
IPv4: the old way of addressing using for sets of digits held in 32 bits.
IPv6: the new way of addressing because there was a huge increase in internet-enabled devices, meaning that the
IPv6 was created which increases the number of available addresses to trillions. They are held in 128 bits.
It gives the device location and can change depending on where you are.
ISP
URL:
e.g. http://www.cie.org.uk/index.htm
- Protocol is ‘http://’
- Domain is ‘cie.org.uk’
- Filename is ‘index.htm’
Cookies:
Cookies: is a packet of information sent by a web server to a web browser. Cookies are generated each time the user
visits the website.
- These can be used to store your personal preferences or log in details, so you don’t need to re-enter these
details. A cookie is stored on the client rather than the server as they are personal to you.
- Tracking cookies are used to gather marketing information, and have your details recorded and then transmitted
back to the cookies author.
- Packet of info sent by web server to web browser (pieces of data). It is generated each time user visits site and
collects key info.
- It cannot destroy or modify data in a computer without the user’s knowledge or generate website pop-ups.
- Can be deleted from a computer. Will not corrupt the data on a customer’s computer
- Data / files
- Stored in a text file
- Downloaded to a user’s computer when a website is visited // webserver sends to web browser
- Stored on a user’s computer
- Stored by a browser
- Detected by the website when it is visited again
X = (A.B) + (B.¬C)
Operating system – the software running in the background of a computer system. It manages many of the basic
functions. It also allows the user to communicate with the software and hardware of the computer
Interrupt – An interrupt is a signal sent from a device (or from some software) to the processor requesting its
attention
Buses – buses move data around the computer and also send out control signals to synchronise the internal
operations, a pathway for transmitting data and instructions
Control unit – controls the operation of the memory, processor and the input/output devices
Control Unit – Used to manage the flow of data through the CPU and interaction between the components of the
processor
Immediate access store (IAS) used to hold data and instructions when they are loaded from main memory and are
waiting to be processed
Accumulator (ACC) - holds data temporarily that is currently being used in a calculation
Operating systems
Features of an operating system:
- Windows – single user (only 1 user can use computer at a time but have many applications open at a time)
- Android
- Linux
When a computer is initially powered up, the initiating programs are loaded into memory from ROM. The programs
run a checking procedure to make sure internal systems (hardware, processor...) are functioning correctly. If no
errors are detected, the operating system is loaded into memory.
- It performs a number of basic tasks, including controlling hardware/file handling (any other suitable
examples)
- It allows the user to communicate with the computer using hardware // without it the user would not be
able to communicate with the computer using hardware
- It provides the user with a user interface // without it the user would not have a user interface to use
- PCs are often used to perform many complex tasks at a time...
– ...the OS is needed to handle this multitasking
– ...therefore, it provides the ability to handle interrupts
Interrupts
Interrupt Signal sent to a processor which may cause a break in execution of the current routine, according to
priorities
It will cause the processor to temporarily stop what it is doing to service the interrupt.
Interrupt requests – the operating system interrupts the processor to handle input from devices such as mouse,
keyboard, printer etc...
An IRQ (interrupt request) value is an assigned location where the computer can expect a particular device to
interrupt it when the device sends the computer signals about its operation.
For example, when a printer has finished printing, it sends an interrupt signal to the computer. The signal
momentarily interrupts the computer so that it can decide what processing to do next. Since multiple signals to the
computer on the same interrupt line might not be understood by the computer, a unique value must be specified for
each device and its path to the computer.
Types of interrupts
Fetch
The data and instructions run from the RAM to the processor on a data bus; this means the wires on the
motherboard leading from the CPU pins to the RAM pins.
Once we have identified the memory location in RAM the data at that location is copied onto the Data Bus (parallel
wires on motherboard).
The data flows along the data bus to the Data Register in the CPU (aka MBR). The data is then copied to the Current
Instruction Register (CIR)
Decode
Once the data is in the CIR (instruction register) the opcode is separated from the operand (instruction separated
from data)
Execute
Once the data is in the CIR (instruction register) the opcode is separated from the operand (instruction separated
from data)
The clock
Every computer has an internal clock that regulates how quickly instructions are executed
The faster the clock speed, the more instructions are fetched, decoded and executed
1. Program
Address bus
counter PC
6. PC
2. Address
incrimented by
register MAR
1
5. Components 3. Memory
of computer data register
system MDR
4. Current
Control bus instruction
register CIR
Instruction
complete
Registers:
o PC (Program Counter) stores address of next instruction to be processed.
o MAR (Memory Address Register) stores address of next instruction to be processed
o MDR (Memory Data Register) stores an instruction that has been fetched from memory
o CIR or IR ((Current) Instruction Register)
o ACC (Accumulator)
Buses:
Buses are the copper tracks on the motherboard that allows data to flow between the processor, memory (RAM)
and peripherals (keyboard, monitor, hard-drive)
- Control buses
This bus carries signals used to coordinate the computer’s activities: can be uni-directional or bi-directional
- Data buses
This bi-directional bus is used to exchange data between processor, memory and input/output devices
- Address buses
Other features
Touch screens:
Used in:
Mobile telephone/tablet
Ticket/information kiosk
Sensor questions
Answering a short sensor question:
State the name, where you put it and how it works/what it does.
Sensor (make sure to name specific sensor) -> ADC (analogy to digital converter) -> send data to microprocessor ->
compare data with predetermined value ->if data met, something happens -> output to output device.
It is an input device
The data from a sensor must be converted from analogue to digital to be processed by a computer
Analogue data is
- Continuous data
- Non-discrete data
- e.g. data such as a sound wave
Digital data is
Output devices
Type of printer Advantages Disadvantages
Laser • Very high quality of printing • Can be expensive to
• Relatively inexpensive to maintain (e.g., fusers)
buy printer • Produce health hazards
• Large toner cartridges and such as ozone or toner
large paper trays particles in the air
• Very fast printing of
multiple documents
Inkjet • High quality of printing • Ink is expensive to buy and
• Very suitable for printing quickly runs out on a large
photos print run
• Inexpensive to buy printer • Usually have small paper
trays
• Can be noisy in operation
compared to laser printer
Dot matrix • Not adversely affected by • Relatively expensive to buy
damp or dirty/dusty printer
atmospheres • Poor print quality
• Allows use of multi-part • Very noisy and very slow at
stationery (carbon copies) printing
• Allows use of
continuous/fan-folded
stationery
Hardware item How the device works Application and how the hardware item
is used
Inkjet printers - uses cartridges/liquid ink - Used for one-off photos and
- sprays ink in droplets on the paper line documents where a few pages of
by line from a moving print head good quality, colour printing are
- makes use of thermal bubble (tiny needed.
resistors heat up ink into a bubble, - Benefits of inkjet: printing may be
which pops and ejects higher quality, can use larger paper
heat)/piezoelectric technology (a tiny sizes, can print onto different
crystal with a tiny electric charge media, no warm-up time
vibrates, ejects ink) - Drawbacks: printing will be slower,
- suitable for low volume (high quality) ink is more expensive per page, ink
output, e.g., a photo can be smeared//is not smudge
Describe how the inkjet printer prints an proof
image
− Rollers are used to move the paper
through the printer
− Nozzles spray/drop/jet ink onto the paper
− Ink jets/print head/nozzles are moved
across the paper (to distribute the ink)
− Different colour inks are mixed to create
required colours
− Technology could be piezoelectric
− Technology could be thermal bubble
− Ink is heated
− ...and expands/evaporates into a bubble
− Bubble is pushed through the nozzle on to
the paper
− ...then the bubble collapses
Sampling rate
Most CDs have a sample frequency of 44,100
hertz (samples per second)
Primary storage
Memory that is directly accessible by the CPU, it can only be internal to the computer. It has a faster access speed
and is both volatile and non-volatile. It stores boot up instructions and can hold data whilst being processed.
ROM
DVD-RAM
Secondary storage
Memory that is not directly accessible by the CPU, it is internal to the computer. It has a slower access speed and is
non-volatile. It stores files/software. Examples include HDD/SSD
Hard disk drive (HDD)
Off-line storage
- Non-volatile storage
- Storage that can be disconnected/removed from the computer. Can be easily disconnected from the
computer -> removable from a computer // not internal // portable
- Not directly accessed by the CPU
- Must be (physically) connected to computer to obtain stored data
- Used to store files as a backup
- Examples include CD/DVD/USB stick/SD card/
DVD
CD
Blu-ray
− DVD has a smaller (storage) capacity // Blu-ray has a larger (storage) capacity
− DVD has two layers (of polycarbonate) whereas Blu-ray disks have a single layer (of polycarbonate)
− DVD has a slower transfer rate (of approximately 10 mbps) // Blu-ray has a faster transfer rate (of approximately
36 mbps)
USB
Removable HDD
Magnetic devices such as hard disk drives use magnetic fields to magnetise tiny individual sections of a metal
spinning disk. Each tiny section represents one bit. A magnetised section represents a binary '1' and a demagnetised
section represents a binary '0'. These sections are so tiny that disks can contain terabytes (TB) of data.
As the disk is spinning, a read/write head moves across its surface. To write data, the head magnetises or
demagnetises a section of the disk that is spinning under it. To read data, the head makes a note of whether the
section is magnetised or not.
Magnetic devices are fairly cheap, high in capacity and durable. However, they are susceptible to damage if dropped.
They are also vulnerable to magnetic fields. A strong magnet might possibly erase the data the device holds.
EXAMPLES:
HHD
• ...so the law company can afford to buy a server with greater storage capacity
• Trusted technology...
Optical storage
Optical devices use a laser to scan the surface of a spinning disc made from metal and plastic. The disc surface is
divided into tracks, with each track containing many flat areas and hollows. The flat areas are known as lands and
the hollows as pits.
When the laser shines on the disc surface, lands reflect the light back, whereas pits scatter the laser beam. A sensor
looks for the reflected light. Reflected light (lands) represents a binary '1', and no reflection (pits) represents a binary
'0'.
• ROM media have data pre-written on them. The data cannot be overwritten. Music, films, software and
games are often distributed this way.
• R media are blank. An optical device writes data to them by shining a laser onto the disc. The laser burns pits
to represent '0's. The media can only be written to once but read many times. Copies of data are often made
using these media.
• RW works in a similar way to R, except that the disc can be written to more than once.
EXAMPLES:
Solid state devices use non-volatile random-access memory (RAM) to store data indefinitely. They tend to have
much faster access times than other types of devices and, because they have no moving parts, are more durable.
Since this type of memory is expensive, solid state devices tend to be smaller in capacity than other types. For
example, a solid-state drive that holds 256 GB might be of a similar cost to a hard disk with several terabytes
capacity.
Solid state devices require little power, making them ideal for portable devices where battery life is a big
consideration. They are also portable due to their small size and durability.
EXAMPLES:
SSD, USB
Data storage
Sound file examples: mp3, wav
Parity checking is used to check whether data has been changed or corrupted following transmission from one
device to another. A byte of data is allocated a parity bit
An error might be not identified because an even number of bits are transposed, or two bits are interchanged.
e.g. when identifying which parity bit is incorrect and explaining how you found the error
− Two bytes/registers have an odd number of 1/0 bits // Two use odd parity
− One byte/register has an even number of 1/0 bits // One uses even parity
− One with an even number of one bits/even parity is incorrect // Register C should have odd parity
Echo checks:
Data is sent back again after being sent to another device, and the sender compares the two sets of data to check if
any errors have occurred during the transmission process. Not reliable because the data can become skewed with
both ways.
Check digits:
An extra value is transmitted to help determine if the data received is correct or incorrect. This value is known as a
check digit. The value of the check digit is usually calculated from the other data being sent
• A digit that is calculated from the data // uses modulo to calculate digit // valid description of modulo //
Multiply each digit by its position and add together, divide the sum by a set number and use remainder as
check digit.
• It is appended / added to the data
• Digit is recalculated when data is entered
• Digits are compared to check for error
• If digits are different, error is detected // If digits match, no error is detected
Checksums:
Another way to find whether data has been correctly transmitted using data sent in blocks and an additional value.
Checksum is another way to see if data has been transmitted correctly. Data is sent in blocks and an additional value
sent at the end of the block.
ARQ:
It uses a timeout and acknowledgement (message sent by the receiver indicating that data has been received
correctly)
Storage files
MIDI files:
Standard adopted by the electronic music industry for controlling devices such as synthesisers and sound cards. MIDI
only stores or transmits commands about the music (the notes etc), and not audio signals.
• Sequence:
• First byte is status byte informs MIDI what function
• MIDI channel is encoded in status byte
E.g.
• Stores a set of commands / instructions for how the sound should be played
• Specifies when each note plays and stops playing // Specifies key on/off
• Specifies duration of the note
JPEG:
- File compression format designed to make photo files smaller in size for storage and for transmission
- Joint photographic Experts Group
- JPEG used to reduce photo file sizes
- Reducing resolution = changing pixels per cm
- JPEG reduce bitmap by a factor between 5 and 15
- Lossy compression
mp3:
mp4:
Data compression
Benefits of compression (general)
Lossless:
- The file is reduced in size for transmission and storage; it is then put back together again later producing a
file identical to the original
- A type of file compression that doesn't lose any data or quality (used in text files)
- Repeating patterns are replaced by data, so that the full quality can be later retrieved, by a compression
algorithm.
- All data bits from original file are reconstructed when file is uncompressed
- Good for files where data loss would be bad
- .zip files are lossless
e.g. why you would use lossless (particularly when compressing source code)
− The file can be restored/decompressed to the exact same state it was before compression/ to original
− (It is a computer program so) no data can be lost // Lossy would remove data
− (Lossless) will give repeating words/sections of word a value// RLE is used // Other valid examples of methods of
lossless compression
Lossy:
- Reduction of file size by permanently removing certain, redundant information from the file
- It is a type of file compression that results in lost data and quality (used in music and images) and file is not
exactly like the original (but difference is usually not noticeable)
- File compression algorithm eliminates unnecessary data bits like MP3 and JPEG
- Cannot get original file back once compressed
e.g. describe how sound files are compressed using lossy compression
• ...such as removing background noise / sounds humans can’t hear // or other suitable example
• Sound is clipped
Advantage of lossy
Disadvantages of lossy
Form of lossless data compression in which runs of data are stored as a single data value and count, rather than as
the original run.
Low level:
1. refers to machine code
2. binary instructions, computer understands => faster, less memory
3. work directly on registers/CPU
4. more control over what happens in computer
5. can use machine specific functions
Features of LLL:
− Closer to/is machine code
− May use mnemonics
− May need an assembler to be translated
− One line of code represents a single instruction
− Machine dependent
− Have direct access to memory locations/registers
Examples of LLL:
− Assembly code
− Machine code
Assembly languages
- use mnemonic codes
- need a translator to be executed
- specific to the computer hardware
- is not machine code
- often used to create drivers for hardware
Translators:
- High level languages need translators to convert code into machine code/binary and low level code needs to be
produced that can be understood by the computer
- Compilers and interpreters both translate high-level languages into machine code
- Assemblers translate programs written in assembly code
- Translates program in high level to - Translates high-level language - Low level to machine code
machine code/LLL into machine code/LLL - Executable machine file
- Executable machine code file - Translates line by produced
produced. line/statement by statement - 1 low level statement to 1
- One high level can make several - Stops if it finds an error machine instruction
machine statements - Will only continue when error is - Can be used without
- Compiled program for general use fixed assembler.
- Generates an error report at the end - No executable machine file - Assembled program for
of translation of the whole program produced. general use
- Translates the entire program in one - One high level may require
go several low level lines
- Interpreted programs require
interpreter.
- Used when program is
developed
Benefits of compiling:
Drawbacks of compiling:
It can:
Prevention:
• Firewalls
• Use of strong passwords and user ids / biometrics
• Anti-hacking software.
• (two-step verification//two-factor authentication)
Two-step//two-factor:
Viruses:
Viruses are programs or a program code which can replicate itself with the intention of deleting or corrupting files,
or cause the computer to malfunctions.
It can:
Prevention:
• Anti-virus software’s
• Staying alert and aware of the emails you open
• Not using software’s from unknown resources.
Anti-virus software:
Phishing:
Phishing is run by a person or a creator that sends out a legitimate looking email and as soon as the recipient clicks
on the link, they are sent to a fake website.
It can:
• Access personal data and this can lead to fraud or identity theft.
Prevention:
The link will redirect a user to a legitimate looking webpage (to steal personal data)
Pharming:
Pharming is a code installed on a user’s hard drive or on the web server; the code will re-direct the user to a fake
website without the user knowing.
It can:
Prevention:
- Anti-spyware software
- The user being alert and aware of strange emails from unknowns.
The code will cause a redirection to a legitimate looking webpage (to steal personal data)
Wardriving:
The act of locating and using wireless internet connections illegally; it only requires a laptop (or other portable
device), a wireless network card and an antenna to pick up wireless signals.
It can:
Prevention:
Spyware/Key-Logging software:
Software that gathers information by monitoring key presses on the user’s keyboard; the information is then sent
back to the person who sent the software. This gives access to all the data entered using a keyboard on the user’s
computer.
It can:
Prevention:
Drop-down boxes // onscreen / virtual keyboard • Means key logger cannot collect data.... and relay it to a third
party
Only requires part of the password • Hacker doesn’t get the full password
Two-step verification // Two-factor authentication • Extra data is sent to device making it more difficult for hacker to
obtain it • Data has to be entered into the same system // if attempted from a remote location, it will not be
accepted
e.g. describe how keylogging software can be used to gain unauthorised access to a customer’s account
Anti-spyware software:
Protection software
VPN (Virtual Private Network): is a method used to add security and privacy to private and public networks. It is
recommended to use in the dark and deep web.
Denial of Service (DOS): An attack that floods networks send request after request until the network itself shuts
down/cannot cope with however many requests.
- Firewall
- Proxy server
- Back data up
- Use surge protection
- Follow correct procedure – regularly saving
- Keep data in a fireproof/waterproof/protective case
- Use verification methods (for deleting files)
Passwords should be complex, different and shouldn’t be meaningful. It should be irrelevant, something like:
W23502Q@#BD9304H.
Bio-metric systems: Bio-metric systems are systems that are protected with things like facial recognition, retina
scan, fingerprints, etc.
Passwords/biometric
- Data cannot be accessed without the use of the password / bio data
- Prevents brute force attacks
e.g. explain why modern smartphones are secured with a biometric system
− Allows quicker access as no need to input password // don’t need to remember password
• Make the password require more characters • Makes the password harder to crack/guess • More possible
combinations for the password
• Make the password require different types of characters • Makes the password harder to crack/guess • More
possible combinations for the password
• Use a biometric device • Hard to fake a person’s biological data // data is unique
• Two-step verification // Two factor-authentication • Adds an additional level to hack • Have to have the set device
for the code to receive it
• Drop-down boxes // onscreen keyboard • To prevent passwords being obtained using keylogger
• Set number of password attempts • Will lock account if attempting to guess • Will stop brute-force attacks
Firewalls: Hardware or software based security layer that is positioned between the internet and network/user
device. Allow a user to set rules for network traffic. Can be used to block access to certain websites. (They do not
automatically stop all malicious traffic)
Proxy Server: Remember the websites you have visited and remembers all the information with it. It keeps the users
IP hidden. Acts as a firewall if a firewall isn’t present on a network (limited functionality).
- Prevents direct access to the webserver // Sits between user and webserver.
- If an attack is launched it hits the proxy server instead // can be used to help prevent DDOS // help prevent
hacking of webserver.
- Used to direct invalid traffic away from the webserver
- Traffic is examined by the proxy server // Filters traffic
- If traffic is valid the data from the webserver will be obtained by the user
- If traffic is invalid the request to obtain data is declined
- Can block requests from certain IP addresses
Security Protocols:
Secure Sockets Layer (SSL)
Secure Sockets Layer (SSL) is a type of protocol (a set of rules used by computers to communicate with each other
across a network). This allows data to be sent and received securely over the internet.
When a user logs onto a website, SSL encrypts the data only the user’s computer and the web server are able to
make sense of what is being transmitted. A user will know if SSL is being applied when they see https or the small
padlocks in the status bar at the top of the screen. Padlocks suggests that it is safe and secure
- The users web browser sends a message so that it can connect with the required website which is secured by
SSL.
- The web browser then requests that the web server identifies itself ‘
- The web server responds by sending a copy of its SSL certificate to the users web browser
- If the web browser can authenticate this certificate, it sends a message back to the web server to allow
communication. Sends signal back to webserver that certificate is authentic/trustworthy (browser authenticated
certificate, if authentic, connection is established)
- Once this message is received, the web server acknowledges the web browser, and the SSL-encrypted (can be
asymmetric, symmetric or both) two way data transfer begins.
- Makes use of (public and private) keys to encrypt data. Encrypted data is meaningless (without decryption key /
if intercepted) (any data sent is encrypted using public and private keys)
e.g. describe the process of SSL and how it provides a secure connection
- Online banking
- Online shopping
- Email
- Cloud based storage
- VPN
- Video conferencing
- Social networking/online gaming
Transport Layer Security (TLS) is similar to SSL but is a more recent security system. TLS is a form of protocol that
ensures the security and privacy of data between devices and users when communicating over the internet. It is
designed to provide encryption, authentication and data integrity in a more effective way.
When a website and user are communicating over the internet, TLS is designed to prevent a third party user or
device into this communication since this causes problems with data security.
- Record protocol, this part of the communication can be used with or without encryption (it contains the data
being transferred over the internet).
- Handshake protocol: this allows the website and the user to authenticate with each other and make use of
encryption algorithms (a secure session between the website and user is established).
Applications of TLS
- Online banking
- Online shopping // Online payment systems
- Email
- Cloud based storage
- Intranet/extranet
- VPN
- VoIP
- Instant messaging (IM) // social networking
Encryption:
Encryption is used to protect data in case it has been hacked. Encryption makes the data meaningless unless it
somehow gets decrypted. There are 2 types of encryptions:
- Symmetric Encryption
- Asymmetric or Public Key Encryption
Symmetric Encryption
Symmetric Encryption is a secret key which can be a combination of different characters. If this key is applied to a
message, its contents is changed and makes it unreadable unless a user has a decryption key which fixes the
problem. One key is needed to encrypt a message and another key is needed to decrypt message.
However this key is very vulnerable to Key Distribution Problem. So the sender and receiver have to have to same
key for encryption and decryption. The sender has to send the key to the receiver and if somehow it gets
intercepted by a hacker, this can lead to a failure in encryption and security making the contents unprotected. The
hacker can easily decrypt the file/data. There is also an encryption algorithm where you use an algorithm to unlock
the file and keep the data safe.
Asymmetric Encryption
Both type of keys is needed to encrypt and decrypt messages. It works like this:
Plain Text: Plain Text is normal text/data before it goes through encryption.
Authentication: Authentication is used to verify that data comes from a trusted source. It works with encryption to
strengthen internet security.
Computer Ethics:
Computer Ethics: a set of principles set out to regulate the use of computers.
e.g. explain what is meant by computer ethics and why the art gallery is concerned about computer ethics
• A set of guidelines
• Tell people how to behave when using computers // helps keep users safe when using computers // by example
• Art gallery could copyright their work (to make it illegal to steal it)
Intellectual Property Rights: this covers copying of software without permission of owners (covers copyright issues
and plagiarism)
Privacy Issues: this covers hacking and illegal access of another person’s personal data
Effect of computers on society: this covers factors such as job losses and social impacts and so on
Copyright: • A law/legislation that requires permission to use intellectual property / other people’s work
Plagiarism: • To claim other’s work as your own • To use other people’s work without consent / acknowledgement •
Theft of intellectual property
show understanding of the ethical issues raised by the spread of electronic communication and
computer systems, including hacking, cracking and production of malware
Free software, freeware and shareware
Free Software: is basically when you download software, you can run it, copy it, change it, it doesn’t
matter. Examples: AbiWord, F-Spot and Scribus.
Freeware: a software a user can download from the internet free of charge. Once it has been downloaded, there are
no extra fees associated with the software. Examples: Adobe, Skype or media players)
• A type of software licence • Free of charge • Normally distributed without the source code • Can legally share /
copy • Cannot legally modify code • Cannot resell
Shareware: a software which users are allowed to try out a software free of charge for a trial period. Examples
(Netflix, Music Apps)
Definitions
HTML a hypertext mark-up language used to create webpages, which is translated by a browser to display webpages
and uses (opening and closing) tags to display content.
Web browser displays the web page, translates the HTML document
Library routine is
Library routines make writing programs easier and faster as the code is already written
Library routines make program testing easier as the code has already been tested and debugged
Sub-routines a set of programming instructions for a given task that performs a sub-system. Written in high-level
languages called ‘functions’
Algorithm sets out steps to complete task. Usually shown as a flowchart or pseudocode.
Definitions:
Structure diagram - shows the hierarchy of the different components which make up a system // an overview of a
program or subroutine. A modelling tool used to show the hierarchy of a system. A graphical representation to show
how a system is broken down into sub-systems
Flowchart - shows the steps representing an algorithm using various shapes of boxes. A graphical representation
used to represent an algorithm
Library routine - pre-written code to include in your own program to carry out a common task // a standard
subroutine (/programs) that is available for immediate use.
Trace table - shows the values of variables as you manually test your program
Test data
Normal data - to work through solution to find actual results and see if they are the same as expected results.
Erroneous/Abnormal data - should be rejected from the solution e.g. out of range, the wrong data type.
Extreme data - the largest and smallest values accepted, this data should be accepted.
Boundary data - uses to establish where the largest and smallest value occur
Test data set 1: 30, 29, 28 Reason: first number is the largest
e.g. explain what is meant by validation and verification. Give an example for each one
Validation:
• automated checking • checking that data is reasonable / of a certain type • checking that data meets certain
criteria
Verification:
• checking that data has not changed... • ...during input to a computer • ...during transfer between computers /
devices
Types of validation:
e.g. describe, with examples, the purpose of these validation checks used in programming
Range check
To test if the value input falls between a given upper bound and a given lower bound, If a month has to be input
using an integer, it must be between 1 and 12 inclusive.
Length check
To test if the data input is over/under a certain number of characters, An international telephone number can be no
longer than 15 digits
Type check
To test if the input is of the correct data type, If the input is expecting integer(s) to be entered, it will not permit a
string to be entered
Types of verification:
Verification checks that data entered is the data that was intended to be entered // can be a human check //
matches the source
Conditional statements:
Loop structures:
FOR … TO … NEXT
REPEAT … UNTIL
WHILE … DO … ENDWHILE
understand and use standard flowchart symbols to represent the above statements, commands and
structures
Conditional statements
Case statements
- CASE...OF...OTHERWISE....ENDCASE
- A statement that allows for multiple selections
- Reason for use: to simplify pseudocode/ to make pseudocode more understandable
Constants
Variables
CASE A OF
100: B ← A
200: C ← A
ENDCASE
IF A > 100
THEN
B←A
ENDIF
FOR A ← 1 TO 100
B←B+1
NEXT A
REPEAT
A ← B * 10
- adding the weight of each basket to the total weight as each weight is entered
Table
Chapter 13 Databases
Databases
A Database is a structured collection of data that allows people to extract information in a way that meets their
needs. The data can include text, numbers, pictures: anything that can be stored in a computer.
Benefits:
- It records and stores all the data, there isn’t data duplication.
- The same data is used by everyone and if there are any changed to be done, they can be easily done once.
- patients in a hospital
- Students at a school
- cars to be sold
- books in a library
- hotel bookings
- results of races
- and many more things
Inside a database, data is stored in Tables, which consist of many Records and each record consists number of Fields.
Example:
In order to be sure that each record can be found easily and to prevent more than one copy of the same record
being kept, each record includes a Primary Key field. Each Primary Key field in the table is unique. The primary key
can be a field that is already used, provided it is unique, for example the ISBN in the book table, or a new field added
to each record, for example, a unique hospital number could be added to each hospital patients record. Sometimes,
a primary key can be formed by using two or more existing fields for example the doctors appointments could have a
primary key made from the date and the time of each appointment.
A foreign key is a field (or collection of fields) in one table that uniquely identifies a row of another table or the same
table.
For making a database, we use Microsoft Access
Validation: Validation is an automatic computer check to ensure that the data entered is sensible and reasonable.
However it does not check the accuracy of data.
Keywords:
Data - raw facts or figures
Relational database - a database with several tables linked by primary key fields
Range - Start/End