Unit 4 - Practice Quiz

CSE316

1 Which of the following is NOT a necessary condition for a deadlock to occur?

A. Mutual Exclusion
B. Hold and Wait
C. Preemption
D. Circular Wait

2 Which deadlock handling strategy involves ensuring that at least one of the necessary conditions for deadlock cannot hold?

A. Deadlock Avoidance
B. Deadlock Prevention
C. Deadlock Detection
D. Deadlock Recovery

3 The Banker’s Algorithm is used for which purpose in an Operating System?

A. Deadlock Prevention
B. Deadlock Avoidance
C. Deadlock Detection
D. Deadlock Recovery

4 A system is in a 'safe state' if:

A. There is no deadlock.
B. There exists a safe sequence of all processes.
C. All resources are currently free.
D. No process is waiting for resources.

5 In a Resource Allocation Graph, if the graph contains no cycles, then:

A. A deadlock exists.
B. A deadlock may exist.
C. No deadlock exists.
D. The system is in an unsafe state.

6 Which technique addresses the 'Circular Wait' condition to prevent deadlock?

A. Spooling resources
B. Requesting all resources at the start
C. Imposing a total ordering of all resource types
D. Allowing preemption

7 What is the primary difference between a Virus and a Worm?

A. A virus is harmless; a worm is malicious.
B. A virus requires a host program to spread; a worm can replicate independently.
C. A worm infects hardware; a virus infects software.
D. A virus spreads via network only; a worm spreads via disk.

8 Which of the following describes 'Starvation'?

A. Two processes waiting indefinitely for each other.
B. A process waiting indefinitely because other processes are constantly favored.
C. The system crashing due to memory overload.
D. A security breach in the kernel.

9 A 'Trapdoor' (or Backdoor) in a system is:

A. A hardware failure.
B. A mechanism to bypass security controls.
C. A type of antivirus software.
D. A protocol for secure file transfer.

10 Which attack involves overwriting a memory area to corrupt data or execute malicious code?

A. Phishing
B. Buffer Overflow
C. Sniffing
D. Denial of Service

11 Which component of the Access Matrix model represents the protection domain?

A. The column
B. The row
C. The intersection cell
D. The file system

12 Implementing an Access Matrix by storing list of objects and rights with each domain is known as:

A. Access Control List (ACL)
B. Capability List
C. Global Table
D. Lock-key mechanism

13 The 'Principle of Least Privilege' states that:

A. Users should have maximum access to ensure efficiency.
B. Programs and users should be given just enough privileges to perform their task.
C. Security should be handled only by the OS kernel.
D. All users should have the same privilege level.

14 Which of the following is a method for Deadlock Recovery?

A. Banker's Algorithm
B. Process Termination
C. Wait-for Graph
D. Ordering Resources

15 What is 'Cache Poisoning'?

A. Physically damaging the cache memory.
B. Introducing false information into a DNS or ARP cache.
C. Filling the cache so no valid data can be stored.
D. Encrypting the cache so the CPU cannot read it.

16 In the context of Deadlock Detection with single instances of each resource type, which structure is used?

A. Banker's Matrix
B. Wait-for Graph
C. Gantt Chart
D. Access Control List

17 Which of the following is an example of a 'Program Threat'?

A. Phishing email
B. Trojan Horse
C. Shoulder surfing
D. Dumpster diving

18 The practice of adding a random string to a password before hashing it is called:

A. Salting
B. Phishing
C. Snooping
D. Spoofing

19 Which recovery method involves rolling back a process to a safe checkpoint?

A. Process Termination
B. Resource Preemption
C. Starvation
D. Mutual Exclusion

20 A 'Logic Bomb' is:

A. A hardware malfunction.
B. Code embedded in a legitimate program that executes when specific conditions are met.
C. A virus that spreads via email.
D. A type of firewall.

21 In an Access Control List (ACL) implementation, the permissions are associated with:

A. The Domain (User)
B. The Object (File/Resource)
C. The Operating System
D. The Network

22 Which of the following is a goal of Protection in an OS?

A. To increase CPU speed.
B. To ensure that resources are used only by those processes that have proper authorization.
C. To maximize memory fragmentation.
D. To prevent the user from installing applications.

23 What is the 'Ostrich Algorithm' in the context of deadlocks?

A. Detecting the deadlock and recovering.
B. Preventing the deadlock strictly.
C. Ignoring the deadlock problem altogether.
D. Avoiding the deadlock using probabilities.

24 Which attack attempts to guess a password by trying every possible combination of characters?

A. Dictionary Attack
B. Brute Force Attack
C. Phishing
D. Trojan Horse

25 What is a 'Denial of Service' (DoS) attack?

A. Stealing user passwords.
B. Encrypting user data for ransom.
C. Preventing legitimate users from accessing a system or network.
D. Injecting a virus into the boot sector.

26 The 'Need-to-Know' principle suggests:

A. Users must know everything about the system.
B. A process should only have access to resources currently required for its task.
C. All files should be readable by everyone.
D. Security is not necessary for internal networks.

27 Which of the following is NOT a standard method for user authentication?

A. Something the user knows (Password)
B. Something the user has (Smart card)
C. Something the user is (Biometrics)
D. Something the user wants (Desire)

28 In the context of protection, a 'Domain' implies:

A. A website address.
B. A set of access rights/privileges.
C. A physical location of the server.
D. The type of operating system used.

29 Which deadlock prevention strategy denies the 'Hold and Wait' condition?

A. Preempting resources from a process.
B. Ordering resources numerically.
C. Requiring a process to request all resources before execution begins.
D. Using the Banker's Algorithm.

30 What is 'Stack Smashing'?

A. Physical damage to the CPU stack.
B. A form of buffer overflow attack targeting the stack.
C. Compressing the stack to save memory.
D. Deleting the stack pointer.

31 A 'Polymorphic Virus' is one that:

A. Changes its signature or code every time it replicates to avoid detection.
B. Infects multiple operating systems.
C. Only attacks graphics files.
D. Cannot be removed.

32 What does 'Mutual Exclusion' mean in the context of deadlock?

A. Processes must share all resources.
B. At least one resource must be held in a non-sharable mode.
C. Resources can be preempted.
D. Processes wait in a circle.

33 Which of the following best describes 'Phishing'?

A. Flooding a network with traffic.
B. Intercepting Wi-Fi signals.
C. Social engineering via email/web to steal credentials.
D. Guessing passwords using a dictionary.

34 In the Lock-Key mechanism for access control:

A. Every user has a physical key.
B. Each object has a list of unique bit patterns (locks) and domains have patterns (keys).
C. The OS uses a master password.
D. It is identical to an Access Control List.

35 One-Time Passwords (OTP) are used to primarily prevent:

A. Buffer overflows.
B. Replay attacks.
C. Virus infections.
D. Deadlocks.

36 Which of the following is a 'System Threat' rather than a 'Program Threat'?

A. Trojan Horse
B. Virus
C. Worm
D. Trapdoor

37 If a process P1 is holding Resource R1 and waiting for R2, and P2 is holding R2 and waiting for R1, this is an example of:

A. Starvation
B. Circular Wait
C. Safe State
D. Preemption

38 Secure communication over a network often relies on:

A. Short passwords.
B. Encryption and Cryptography.
C. Open access points.
D. Faster routers.

39 Man-in-the-middle (MitM) attack involves:

A. An attacker secretly relaying and possibly altering communication between two parties.
B. An attacker guessing the password.
C. An attacker destroying the server hardware.
D. An attacker locking the database.

40 A 'Stealth Virus' attempts to:

A. Encrypt the hard drive.
B. Hide its presence from the OS and antivirus software.
C. Make the screen go black.
D. Delete the boot sector immediately.

41 Which of the following is a weakness of the Global Table implementation of the Access Matrix?

A. It is too secure.
B. The table can become extremely large and cannot be kept in main memory.
C. It does not support file permissions.
D. It allows everyone to access everything.

42 When a system recovers from deadlock by rolling back a process, what issue must be addressed to prevent the same process from being picked repeatedly?

A. Starvation
B. Mutual Exclusion
C. Throughput
D. Latency

43 What is the main disadvantage of Deadlock Detection compared to Deadlock Prevention?

A. It restricts resource usage.
B. It requires runtime overhead to run the detection algorithm.
C. It never finds deadlocks.
D. It requires user intervention.

44 In protection systems, switching from one domain to another (Domain Switching) typically happens when:

A. A user logs out.
B. A process calls a system call or changes privilege level.
C. The computer is restarted.
D. A file is deleted.

45 The 'Confidentiality' aspect of security ensures that:

A. Assets are accessible to authorized parties.
B. Assets can only be modified by authorized parties.
C. Assets are accessible only to authorized parties.
D. The system is always running.

46 Which of the following is an example of a 'Day Zero' or 'Zero-Day' attack?

A. An attack that happens at midnight.
B. An attack exploiting a vulnerability before the developer knows about it or has a fix.
C. An attack that deletes 0 bytes.
D. An attack using 0s and 1s.

47 Password 'Salting' makes which specific type of attack much more difficult?

A. Brute Force
B. Dictionary Attack using Rainbow Tables
C. Phishing
D. Social Engineering

48 In the context of Application Security, 'Input Validation' helps prevent:

A. Deadlock
B. Buffer Overflow and SQL Injection
C. Starvation
D. Packet Sniffing

49 What is 'Network Sniffing'?

A. Smelling the hardware for burning components.
B. Monitoring and capturing data packets passing through a network.
C. Cleaning the network cables.
D. Speeding up the network connection.

50 Which concept ensures that a modification to a system asset is done only in an authorized manner?

A. Availability
B. Confidentiality
C. Integrity
D. Authentication