CP2414 All Short Answer Questions
CP2414 All Short Answer Questions
Week 1
2. Give 3 computer security challenges, explain why they are challenging, and
how to tackle the challenges.
Cyber Attacks and Threats
Increasingly sophisticated forms of cyber threats, such as malware,
ransomware, phishing, and denial-of-service (DoS) attacks, and the speed at
which they evolve pose significant challenges for computer security.
Implement a multi-layered security approach that includes firewalls,
intrusion detection systems, and antivirus software. Regularly update and
patch systems to protect against known vulnerabilities. Educate users about
online safety.
Insider Threats
Insider threats, whether malicious or accidental, are a significant
security challenge. Employees or other insiders may unintentionally expose
sensitive data through careless actions, or they may intentionally steal or
damage data.
Implement strict access control measures, ensuring that individuals can
only access the data necessary for their job roles. Provide regular training to
employees to enhance their awareness of security protocols and the
potential consequences of carelessness. Monitor user activities to detect
and respond quickly to any unusual or suspicious actions.
Cloud Security
Data stored in the cloud can be accessed from anywhere, which
increases the potential attack surface. Additionally, organizations often lack
visibility and control over their data in the cloud.
Use encryption for data at rest and in transit. Implement strong user
authentication methods, such as two-factor or multi-factor authentication.
Establish clear policies regarding data management in the cloud.
5. Give 5 fundamental security design principles and explain each one of them
(do not copy from lecture slides or textbook – explain from your
understanding).
1.Least Privilege: Users and systems should only have the minimum levels of
access – or permissions – necessary to perform their tasks. This reduces the risk of an
attacker gaining elevated privileges or of an accidental misuse of privileges causing
extensive damage.
5.Economy of Mechanism: This principle calls for keeping systems simple and
straightforward. A simple design is easier to test and secure, as complexity often
hides security flaws.
6.Open Design: The security of a system should not depend on the secrecy of
its design or implementation. It should be secure even if the attackers know how the
system works. The security should rely on publicly known and thoroughly tested
security mechanisms.
Complete Mediation: Every access to every resource must be checked for
permissions. The system should not rely on cached permissions or assume that a
previous check is sufficient for subsequent accesses.
Least Astonishment: A user interface should behave in a way that users expect it
to, which means that programs and operations should perform in a manner
consistent with user expectations. This helps prevent users from making dangerous
mistakes that could lead to security breaches.
6. Explain the term “drive-by download”. How can attackers perform the
attack?
“Drive-by download” refer to the unintended download of malicious
software (malware) to a user's system — without consent. This also includes
unintentional downloads of any files or bundled software onto a computer
device.
An attacker performs a drive-by download attack generally by injecting
malicious code into a website, or by planting a malicious file as attachments in
an email. When a user visits that website or opens the attachment in the email,
the code is automatically executed, which then downloads and installs malware
on the user's device without their knowledge.
7. What is SQL injection?
SQL Injection is an attack that enables attackers to manipulate the SQL
queries used by a web application to interact with its database. By injecting
malicious SQL commands into input fields, attackers can trick the application into
executing unintended commands, potentially allowing them to view, modify, or
delete data.
9. What is Session Hijacking? Why would the attacker want to hijack a session
token?
Session hijacking is a type of attack where an attacker intercepts and steals
the session token from a user's communication with a server. Once the attacker
has the session token, they can use it to impersonate the user, gaining
unauthorized access to the server and its associated resources.
Bypassing login mechanisms
Access to unauthorized information
Perform actions as the user
2.Perform actions as the user: Not only can the attacker see what the user can
see, but they can do what the user can do. They could send messages, conduct
transactions, or perform any other actions as if they were the hijacked user.
1. How can you prevent an SMTP server from sending unable to deliver the
message back to spammers (draw a diagram/picture if you’d like and explain)?
Why is it important to do so?
Implementing Sender Verification: Only accept emails from known, valid
senders.
Using Spam Filters: Detect and block spam before it enters your system, thus
avoiding Non-Delivery Report (NDR) for spam messages.
Backscatter Protection: Tools that identify and filter bounce messages that were
not caused by your own system.
It is important to implement these measures to prevent spammers from confirming
that the email addresses they are targeting are valid. It also reduces the load on your
email servers and helps protect your domain reputation.
3. What is a Virtual Private Network (VPN)? And what are VPN concentrators?
A VPN is a technology that creates an encrypted connection over a less secure
network, typically the internet. It allows users to send and receive data across shared
or public networks as if their devices were directly connected to the private network.
5. What is “port security”? What are the techniques can you use to protect the
ports?
Port security refers to the defense mechanisms used to protect network ports against
unauthorized access and threats. Techniques include:
MAC Address Filtering: Restricting the devices that can connect to a network
based on their MAC address.
Port-based Authentication: Using Port-Based Network Access Control (PNAC)
protocols like 802.1X to authenticate devices before granting access to the
network.
Disabling Unused Ports: Physically disconnecting or administratively disabling
ports that are not in use.
8. A company has asked for your opinion on their network infrastructure as follows:
• Its employees are to have access to their computing devices over the internet,
how would NAT technologies be used for that?
NAT for Remote Access: NAT (Network Address Translation) can be used to allow
employees to access their computing devices over the internet by translating public
IP addresses to private IP addresses and vice versa. This hides internal IP addresses,
adding a layer of security.
• In addition, the company employees’ desktop/devices are not located within their
department areas, as they may move among the different departments or floors if
the employees have more than one main duty. What would you think is the best
solution? Explain why the solution is recommended in relation to network security.
A Virtual LAN (VLAN) setup allows network administrators to group servers and
devices on separate VLANs as if they were on different physical networks, even if
the employees move physically. This maintains network security by segregating
traffic and reducing the potential for data leakage between departments.
Week 3
2. There are two ways to protect a password file. What are they? Explain.
Password file protection: There are several ways to protect a password file:
One-way function - Password Hashing: Instead of storing plaintext passwords, systems store
a cryptographic hash of the password. When a user enters their password, the system hashes
the input and compares it to the stored hash. This way, even if the password file is
compromised, the attacker cannot easily derive the original passwords.
Access control - File System Permissions: The password file should have strict permissions,
such that only necessary processes can read it. This limits the potential for unauthorized
access.
a. Threshold detection: This approach involves defining thresholds, independent of user, for
the frequency of occurrence of various events.
b. Profile based: A profile of the activity of each user is developed and used to
detect changes in the behavior of individual accounts.
Uses: Honeypots can be used to distract attackers, gather intelligence about attack methods,
and help develop defenses against future attacks.
9. What is the difference between a packet filtering firewall and stateful inspection packet
firewall?
Packet Filtering Firewall vs Stateful Inspection Firewall:
Packet Filtering Firewall: This type of firewall inspects packets individually and makes allow
or deny decisions based on rules involving source and destination IP addresses, ports, and
protocols.
Stateful Inspection Firewall: Goes beyond packet filtering by keeping track of the state of
active connections and making decisions based on the context of the traffic (e.g., TCP
handshake completion), watching for legitimate initiated sessions and preventing unsolicited
packets from entering the network.
11. Explain distributed firewall configuration. Where can the firewalls be placed? Why are
they placed there?
Distributed Firewall Configuration refers to the implementation of firewall functionality
across multiple points within a network architecture rather than centralizing it at a single
point.
Network Perimeter: Firewalls are placed at the network perimeter to control all
inbound and outbound network traffic, serving as a barrier that prevents external
threats from infiltrating the organization's internal systems.
Outside the Internal Network: Firewalls positioned outside the internal network, but
still within the organization's overall network framework, are intended to safeguard the
internal network where critical assets and sensitive data reside.
Within the Internal Network: Implementing firewalls within the internal network allows
for creations of different security segments, containing potential security breaches to a
limited area.
Week 4
2. Explain the difference between a block cipher and a stream cipher in plain-text processing.
Block Cipher: Encrypts data in fixed-size blocks (e.g., 128 or 256 bits) and requires padding if
the plaintext does not exactly fit the block size.
Stream Cipher: Encrypts data one bit or byte at a time and is often used where data is
streamed continuously.
3. In cryptanalysis, given types of attack below, explain what is known to a crypt-analyst for
each type of the attacks.
(a) Ciphertext only: The cryptanalyst has access only to the encryption algorithm and
the ciphertext to be decoded.
(b) Known plaintext: The cryptanalyst has access to the encryption algorithm, the
ciphertext to be decoded, and part of the plaintext and its corresponding ciphertext.
(c) Chosen plaintext: The cryptanalyst has access to the encryption algorithm, the
ciphertext to be decoded, and can choose arbitrary plaintext and obtain their corresponding
ciphertexts.
6. Briefly explain:
• Data Encryption Standard (DES): An older encryption algorithm that uses a 56-bit key,
now considered insecure due to its small key size and rather slow.
• Triple DES (3DES): An enhancement to DES that applies the DES cipher algorithm three
times to each data block, using three keys for better security. Considered adequately secure
but very slow.
(b) Unpredictability: Means the inability to foresee the next number in a sequence. Each
element is independent from other elements. They cannot be inferred by previous element.
This Independence ensures unpredictability.
Week 5
3. What is the problem with message authentication approaches that do not rely
on encryption?
Message confidentiality is not provided. As was mentioned, message encryption
by itself does not provide a secure form of authentication. However, it is possible to
combine authentication and confidentiality in a single algorithm by encrypting a
message plus its authentication tag.
7. What is SHA?
SHA stands for Secure Hash Algorithm. It's a family of cryptographic hash
functions used to ensure data integrity. It was published by the National Institute of
Standards and Technology (NIST). Examples include SHA-1, SHA-256, and SHA-3.
3. Public key: A key that is available to the public and is used for encryption.
5. Private key: A key that is kept secret and is used for decryption.
11. What is RSA? What are the possible attack approaches that can be done on
RSA? Explain.
RSA (Rivest-Shamir-Adleman) is a public-key scheme for secure data
transmission.
Mathematical attacks: There are several approaches, all equivalent in effort to
factoring the product of two primes. The defense against mathematical attacks is
to use a large key size. Thus, the larger the number of bits, the better.
Timing attacks: These depend on the running time of the decryption algorithm.
Various approaches to mask the time required so as to thwart attempts to
deduce key size have been suggested, such as introducing a random delay.
Chosen ciphertext attacks: This type of attack exploits properties of the RSA
algorithm by selecting blocks of data that, when processed using the target’s
private key, yield information needed for cryptanalysis. These attacks can be
thwarted by suitable padding of the plaintext.
1. Each party generates a pair of keys - a private key which is kept secret, and a
public key which is shared openly. These keys are mathematically linked: operations
performed with one key can be undone or verified with the other key.
2. Each party shares their public key with the other party.
3. Upon receiving the other party's public key, each party combines this public
key with their own private key to compute a shared secret.
4. The shared secret is the same for both parties, and can be used as a
symmetric key for further encrypted communication.
Week 6
2. What are the four general means of authenticating a user’s identify? Explain.
What you know: Information that the user can memorize, such as passwords,
PINs, or answers to secret questions.
What you have: Physical objects in the user's possession, such as smart cards,
tokens, or mobile phones used for authentication.
What you are: Biometric characteristics of the user, such as fingerprints, facial
recognition, iris scans, or voice recognition.
What you do: Behavioral biometrics, which include patterns in the way a user
types, uses a mouse, or other behavioral traits.
3. In Symmetric key distribution, how is the permanent key used for distributing
session keys?
A permanent key, also known as a master key, is a secret key shared between
two parties or with a key distribution center (KDC). This key is used to encrypt and
securely distribute session keys. The session keys are then used for a limited time to
encrypt communications during a session. Once the session is over, the session key is
discarded, and a new one will be generated for future communications.
4. With regards to Kerberos, what are timestamp and lifetime of a ticket (issued by
the Ticket Granting Server (TGS))? And why are they important?
Timestamp: This is the time at which the ticket was issued.
Lifetime: This is the duration for which the ticket is valid.
They can be used to prevent replay attacks.
6. What is the main problem with publishing a public-key? And how has the
problem been tackled?
The main problem with publishing a public key is ensuring its authenticity - that
it truly belongs to the person or entity claiming to own it. Users could be tricked into
encrypting messages with a key provided by an attacker.
This problem is tackled through the use of Public Key Infrastructure (PKI), where
a trusted third party known as a Certificate Authority (CA) verifies the identity of the
key holder and issues a digital certificate that binds the public key to the individual or
entity. Users can then verify the certificate to ensure the public key's authenticity
before use.
Week 7
2. What is the quarantine network, and what is the purpose of having it?
A quarantine network is a designated, restricted segment of a computer network
where devices that do not meet the defined security policy are placed. Its purpose is
to isolate non-compliant devices to prevent the spread of malware until they can be
brought into compliance.
(b) Virtual local area networks (VLANs) are used to segment networks into smaller
parts for reducing broadcast traffic. VLANs can isolate sensitive data and limit access
to specified users, thereby acting as a method for enforcing NAC policies.
Abuse of cloud computing: It’s easy to register and become an insider of cloud
computing.
Countermeasures: Enforce stricter initial registration and validation processes.
Data Encryption: Encrypt data before uploading it to the cloud and keep control
of the encryption keys.
Secure APIs: Use secure APIs and ensure they are constantly updated and
monitored for unauthorized access attempts.
10. Give five examples of cloud security as a service (SecaaS) and explain each
example.
Identity and Access Management (IAM): Controls who is authenticated and
authorized to use resources.
Data Loss Prevention (DLP): Ensures sensitive data is not lost, misused, or
accessed by unauthorized users.
Intrusion Management: Detects and responds to cyber threats to protect cloud
services.
Security Assessment: Evaluates the security posture of cloud services and
suggests improvements.
Security Information and Event Management (SIEM): Provides real-time
visibility and analysis of security alerts generated by applications and network
hardware.
Week 8
1. What are the characteristics of the World Wide Web that make it vulnerable to a
variety of security attacks?
Openness: It's designed to be open and accessible, which exposes it to
unauthorized access.
Complexity: Web technologies are complex and interdependent, increasing the
attack surface.
Connectivity: Constant connectivity provides more opportunities for attacks.
Anonymity: Users can interact with web services without revealing their identity,
making it difficult to track malicious actors.
Decentralization: The web has no central authority, which makes consistent
security policies and standards difficult to enforce.
2. Threats on the Web can be categorised into 4 categories. What are they? Give 2
examples of each threat and how to prevent or tackle such threats.
Integrity Threat
An integrity threat is when unauthorized modifications are made to data, which can
lead to misinformation or system malfunctions.
SQL Injection: This occurs when an attacker inserts or "injects" a malicious SQL
query via the input data from the client to the application.
Prevention: Use prepared statements and parameterized queries. Validate and
sanitize all user inputs.
Cross-site Scripting (XSS): This is when attackers inject malicious scripts into
content from otherwise trusted websites.
Prevention: Implement content security policies, encode data on output, and use
appropriate response headers to prevent browsers from interpreting injected
scripts as legitimate.
Confidentiality Threat
A confidentiality threat involves unauthorized access to sensitive data.
SYN Flood: An attacker sends a succession of SYN requests to the target's system
in an attempt to consume enough server resources to make the system
unresponsive to legitimate traffic.
Prevention: Use firewall rules to limit the rate of SYN packets, employ SYN
cookies, and leverage DDoS protection services.
Network Flood: The attacker overwhelms the network with a large amount of
traffic which could be through a botnet in case of a DDoS.
Prevention: Implement rate limiting, use anti-DDoS services, and configure
network hardware to mitigate traffic floods.
Authentication Threat
Authentication threats occur when an attacker gains access to a system by
circumventing or breaking the authentication mechanism.
4. Explain how TLS Record Protocol provides confidentiality and message integrity
services.
Confidentiality: The Handshake Protocol defines a shared secret key negotiated
during the TLS handshake. The key is used for conventional encryption of TLS
payloads.
Message Integrity: The Handshake Protocol also defines a shared secret key that
is used to calculate a message authentication code (MAC).
6. SSL/TLS attacks can be divided into four groups; what are they? Explain.
1. Attacks on the Handshake Protocol
The handshake protocol is used to establish the security settings for a TLS
connection. During the handshake, the client and server agree on various parameters
to establish a secure connection.
7. Explain HTTPS.
HTTPS stands for HyperText Transfer Protocol Secure. It is the secure version of
HTTP, where communications are encrypted by TLS or SSL. This protocol is used for
secure transactions and to prevent unauthorized interception of data.
Public Key Authentication: The client sends a message to the server that
contains the client’s public key, with the message signed by the client’s private
key. When the server receives this message, it checks whether the supplied key
is acceptable for authentication, and, if so, it checks whether the signature is
correct.
Host-Based Authentication: Authentication is performed on the client’s host
rather than the client itself. Thus, a host that supports multiple clients would
provide authentications for all its clients. This method works by having the client
send a signature created with the private key of the client host. Thus, rather than
directly verifying the user’s identity, the SSH server verifies the identity of the
client host—and then believes the host when it says the user has already
authenticated on the client side.
10. One of the most useful features of SSH is port forwarding. Explain what port
forwarding is and how it works.
Port forwarding via SSH, or SSH tunneling, creates a secure connection between
a local computer and a remote machine through which services can be relayed.
Local Port Forwarding: This allows you to connect from your local machine to remote
server through your SSH client.
Week 9
1. Give four key factors contributing to the higher security risk of wireless networks
compared to wired networks. Explain each factor.
Channel: Wireless networking typically involves broadcast communications,
which is far more susceptible to eavesdropping and jamming than wired
networks. Wireless networks are also more vulnerable to active attacks that
exploit vulnerabilities in communications protocols.
Mobility: Wireless devices are, in principal and usually in practice, far more
portable and mobile than wired devices. This mobility results in a number of
risks, described subsequently.
Resources: Some wireless devices, such as smartphones and tablets, have
sophisticated operating systems but limited memory and processing resources
with which to counter threats, including denial of service and malware.
Accessibility: Some wireless devices, such as sensors and robots, may be left
unattended in remote and/or hostile locations. This greatly increases their
vulnerability to physical attacks.
7. What are the five phases of a Robust Security Network (RSN)? Explain.
1. Discovery: Devices discover each other's security capabilities.
2. Authentication: Establishes the identity of devices.
3. Key Generation and Distribution: Encryption keys are created and distributed.
4. Protected Data Transfer: Data is encrypted and securely transmitted.
5. Connection Termination: The secure connection is properly closed.
10. Explain the relationship between Group Master Key (GMK) and Group Temporal
key (GTK).
The Group Master Key (GMK) is a key used to generate Group Temporal Keys (GTKs).
The GMK is held by the access point and is used to derive new GTKs, used to encrypt
traffic in a wireless network.
Week 10
1. What are the three functional areas the IP-level security encompasses? Briefly
explain their functionality.
Authentication: The goal of authentication in IPsec is to verify that the received
packets are indeed from the claimed sender and have not been altered during
transit.
Confidentiality: Confidentiality ensures that the data being sent is only readable
by the intended recipient. This is typically referred to as encryption.
Key Management: Key management encompasses the methods and protocols
used to generate, distribute, and maintain cryptographic keys in an IPsec
environment.
6. Other Components:
4. Explain the transport mode and tunnel mode for Authentication Header and
Encapsulating Security Payload (ESP) protocol.
AH Transport Mode: The AH header is inserted after the original IP header and
before the payload, and it covers the IP payload and AH header for authentication.
The IP header itself is not protected.
ESP Transport Mode: ESP in transport mode encrypts and optionally authenticates
the IP packet's payload only. It does not protect the IP header, so while the data is
confidential, information in the IP header is visible.
ESP Tunnel Mode: ESP in tunnel mode encrypts the entire inner IP packet and
provides optional authentication. The inner packet is encrypted.
7. What are two ways in which security associations may be combined into
bundles? Briefly explain them.
Transport adjacency: Multiple SAs are applied in sequence to the same IP packet
without tunneling.
Iterated tunneling: An IP packet is subjected to multiple layers of SAs, with each
layer corresponding to a different tunnel.
9. What are the roles of the Oakley key determination protocol and ISAKMP in
IPsec?
Oakley Key Determination Protocol: A key agreement protocol based on the
Diffie-Hellman algorithm, used to establish a shared secret over an insecure
channel.
ISAKMP (Internet Security Association and Key Management Protocol): Defines
procedures and packet formats to establish, negotiate, modify, and delete
security associations. ISAKMP works with Oakley to establish the shared secret
keys.