1. Explain what vulnerability and threat mean in security
A vulnerability is a flaw or weakness in the design, implementation or operation of a system that could be exploited to violate it's security (e.g. weak password policy). A threat is a potential for the violation of security, which exists when an attacker has both the capability and intent to breach security.
2. State a common feature of viruses and worms and a difference between viruses and worms
Worms and viruses both self-replicate (& spread) rapidly and cause harm to a computer, but worms are standalone while viruses must replicate into a host program in order to infect a computer and spread.
3. Can hashing be used as a method of encryption? Explain your answer
Hashing is a one-way function, hence it is computationally infeasible to reverse. In the context of encryption, this means we cannot "decrypt" a hashing function. Hence, hashing fulfills only 3 of the 4 properties of a good encryption scheme (confusion, diffusion and difficulty to break). It is not, however, feasible since there is not way to decrypt the ciphertext.
(Question 4 is not relevant to the 2022 Exam, so it is left out here.)
5. What is Discretionary Access Control (DAC)? There are two ways to represent permissions in DAC, namely Access Control Lists and Capabilities. Explain how ACLs and Capabilities store permissions.
DAC, used in standard Linux, tasks the creator of a data object with creating entries in an associated Access Control List, stating which permissions a user or group has regarding operations on said object (i.e. Capabilties). An example of a cabilitiy is read/write permission. This is "discretionary" in the sense that the creator of the object has control over permissions.
GO OVER ACCESS CONTROL
6. Explain what monoalphabetic and polyalphabetic substiution are. Which substitution technique is more resilient to frequency attack? Explain why
Monoalphabetic substiution maps each character in the alphabet to a different character in a rearranged alphabet (e.g. caesar cipher). The same plaintext character is always mapped to the same ciphertext character.
Polyalphabetic substitution maps each plaintext character to a ciphertext character using a different mapping alphabet (e.g. vigenere cipher).
The latter is more resilient to frequency attack since there is no linear relation between plaintext and ciphertext characters, and hence the encryption cannot be reversed by relatinf on the frequencies of PT and CT characters.
7. What is a one-way function in security? Give two examples of one-way functions that are used in security.
A one-way function is a mathematical function which is easy to perform in one direction, but computationally infeasable to reverse/perform the inverse. Examples of this in security include modular exponentiation (used in RSA) and hashing functions (e.g. MD5).
8. Assume Alice and Bob use the Diffie-Hellman-Merkle (DHM) key exchange protocol to establish a secret key. Assume Alice and Bob choose 8 and 11 as the secret numbers, respectively. What is the secret key exchanged between them? You should show the main steps used in the DHM protocol to generate the secret key.
Alice and bob must also agree on a large prime number and it's primitive root . Bob then calculates and alice . They then send these numbers to each other, and exponentiate again, to produce the secret key .
9. Discuss why public key encryption algorithms, such as RSA, are generally much slower than secret key encryption algorithms, such as AES
Public key encryption algorithms generally make use of one-way functions, which are dependent of large key lengths (e.g. the difficulty of reversing modular exponentiation depends on the size of the prime used), resulting in computationally expensive calculations.
Secret key algorithms make use of bitwise operations such as XOR and binary shifts, which are much faster to perform. Also, a comprable level of security can be achieved with a much shorter key, which again reduces the difficulty of the computation.
10. Explain how Digital Signatures protect data integrity
Integrity is the ability to recognise whether a piece of data has been unexpectedly altered. Digital signatures involve hashing a piece of data, encrypting this with the sender's private key, and appending this with the data to be sent. The recipient can decrypt this with the sender's public key and compare it to the hash of the recieved data. The hash is only equal if the data is identical. Thus, Digital Signatures allow us to recognise if the data has been changed in transit, thereby protecting data integrity.
11.
(a) There are different methods for cracking passwords. Discuss the problems with brute force attacks, dictionary attacks and lookup table attacks; dicsuss how the reverse lookup table method overcomes the problems.