Introduction to Cyber Security
Comprehensive exam revision notes for BCA-431E Unit 2 (Classes of Security Attacks & Security Models). Includes Section A (2M), Section B (5M), and Section C (15M) questions, answers, and diagrams.
Introduction to Cyber Security
Classes of Security Attacks & Security Models
Core Definitions & Key Concepts
Passive Attacks and Active Attacks
- Passive Attacks: Monitor or listen to transmissions to obtain information without altering data or system resources (e.g., eavesdropping, traffic analysis). Hard to detect, prevented via encryption.
- Active Attacks: Involve modification of the data stream or creation of a false stream (e.g., masquerade, replay, message modification, DoS). Detected and recovered via integrity controls.
A Denial of Service (DoS) Attack
An attack designed to shut down a machine, service, or network, making it inaccessible to its intended users by overwhelming the target with spurious traffic or triggering a crash condition.
What is a Distributed Denial of Service (DDoS) Attack
A large-scale DoS attack launched simultaneously from thousands of compromised distributed internet machines (a botnet of infected zombies) controlled by a botmaster.
A Man-in-the-Middle (MitM) Attack
An attacker secretly intercepts and relays communications between two parties who believe they are communicating directly with each other (e.g., via ARP poisoning or rogue Wi-Fi access points).
What is ARP Poisoning (ARP Spoofing)
An attack where an adversary sends forged ARP replies over a local area network (LAN) to associate the attacker's MAC address with the IP address of the legitimate default gateway, redirecting all LAN traffic through the attacker.
What are the two core rules of the Bell-LaPadula Security Model
- Simple Security Property (No Read Up): A subject at a given security clearance cannot read an object at a higher classification level (L(S) ≥ L(O)).
- $\star$-Property (No Write Down): A subject at a higher clearance cannot write data to an object at a lower classification level (L(S) ≤ L(O)).
What is the primary focus of the Biba Integrity Model
The Biba Model focuses strictly on data integrity (preventing unauthorized modification) using dual rules:
- Simple Integrity (No Read Down): A subject cannot read an object of lower integrity.
- $\star$-Integrity (No Write Up): A subject cannot write to an object of higher integrity.
What is the Clark-Wilson Security Model
An integrity model designed for commercial environments based on transactions: ensures data can only be modified through certified Transformation Procedures (TPs) applied to Constrained Data Items (CDIs), enforcing separation of duties.
The Chinese Wall (Brewer-Nash) Security Model
A security model developed to avoid conflicts of interest in commercial consulting and finance. It dynamically restricts access: an analyst who accesses data belonging to Company A is immediately barred from accessing data belonging to Company B (Company A's competitor).
What is a Replay Attack and how is it mitigated
An active attack where valid network data transmission is maliciously captured and repeated later. Mitigated using cryptographic nonces, sequence numbers, and ephemeral session timestamps.
Conceptual & Architectural Analysis
Compare the Bell-LaPadula Confidentiality Model vs Biba Integrity Model
| Dimension | Bell-LaPadula (BLP) Model | Biba Model |
|---|---|---|
| Primary Objective | Confidentiality (Prevents data leakage) | Integrity (Prevents data corruption) |
| Read Rule | No Read Up (Simple Security) | No Read Down (Simple Integrity) |
| Write Rule | No Write Down (\star-Property) | No Write Up (\star-Integrity) |
| Domain | Military / Government intelligence | Commercial enterprise, banking, accounting |
| Philosophy | Prevent secret info from leaking down | Prevent low-integrity noise from polluting high integrity |
SYN Flood DDoS Attack and SYN Cookies Defense
TCP 3-Way Handshake Exhaustion
Attacker (Botnet) Target Server
| |
| ----- 1. Send SYN ------------> | -> Allocates TCB in Half-Open Queue
| | (Sends SYN-ACK)
| (Never sends final ACK!) | -> Half-Open queue fills up to 100%
| | -> Legitimate users DROPPED!- Defense (SYN Cookies): Server does not allocate memory for half-open connection. Instead, it encodes client IP, port, and secret salt into the initial TCP sequence number. Memory is allocated only when client returns valid sequence number + 1 in final ACK.
DNS Amplification and Reflection DDoS Attacks
In a DNS Amplification Attack:
- Attacker sends small UDP DNS query packets (e.g., 60 bytes) requesting maximum records (
ANY). - Attacker spoofs the source IP to be the victim's server IP.
- The public recursive DNS resolvers send massive amplified responses (up to 3000 bytes - a 50× amplification factor) directly to the unsuspecting victim, saturating their bandwidth.
The Clark-Wilson Model Components (CDI, UDI, TP, IVP)
- Constrained Data Item (CDI): Highly sensitive data items whose integrity must be preserved (e.g., ledger balances).
- Unconstrained Data Item (UDI): Unvalidated inputs from outside world.
- Transformation Procedure (TP): Certified programs that alone have permission to alter CDIs.
- Integrity Verification Procedure (IVP): Confirms that CDIs conform to valid system state.
Smurf and Fraggle Attacks
- Smurf Attack: Attacker sends ICMP Echo requests (pings) with a spoofed victim source IP to an IP broadcast address; all LAN hosts reply simultaneously to the victim.
- Fraggle Attack: Similar to Smurf, but utilizes UDP echo packets (Port 7) instead of ICMP.
In-Depth Analysis & Implementation
Provide an In-Depth Analysis of the Bell-LaPadula Mathematical Security Model, Proving How the \star-Property Prevents Covert Downward Leaks
Formal Mathematical Analysis of Bell-LaPadula (BLP 1973)
1. Mathematical Elements:
- Let S be the set of Subjects (users, processes).
- Let O be the set of Objects (files, databases, memory segments).
- Let (L, ≤) be a partially ordered lattice of security classifications:
$Unclassified < Confidential < Secret < Top Secret$
- Each subject has clearance L(s) \in L, and each object has classification L(o) \in L.
2. The Two Axiomatic Properties:
[ Top Secret Object ]
^ |
| | CANNOT READ UP
CANNOT WRITE | |
DOWN (*) | v
[ Secret Subject ]
^ |
| | CAN READ DOWN
CAN WRITE | |
UP (*) | v
[ Unclassified Object ]- Simple Security Property (ss-property - No Read Up):
A subject s may have read access to an object o if and only if: $L(s) ≥ L(o)$ Proof: A user with Secret clearance can read Unclassified or Secret documents, but cannot view Top Secret records.
- The $\star$-Property (Star Property - No Write Down):
A subject s with read access to an object o_1 may have write access to an object o_2 if and only if: $L(o_2) ≥ L(o_1) *(Or in discretionary form: L(o) \ge L(s)$)*.
3. Mathematical Proof of Leak Prevention:
- Suppose the \star-property did not exist.
- A malicious Trojan Horse process running with Top Secret clearance could read a Top Secret cryptographic key (o_1).
- The Trojan could then open an Unclassified log file (o_2) and write the secret key into it.
- Any user with Unclassified clearance could then read o_2 and steal the Top Secret key!
- By enforcing L(o_2) ≥ L(s), the Top Secret process is strictly prohibited from writing to any object below Top Secret clearance. Thus, downward information flow is mathematically impossible. \blacksquare
Detail the Mechanics of ARP Cache Poisoning and Man-in-the-Middle Attacks with Packet Flow Schematics and Python Scapy Script
ARP Cache Poisoning Architecture
[ VICTIM (Client) ] [ ATTACKER ] [ GATEWAY (Router) ]
IP: 192.168.1.50 IP: 192.168.1.100 IP: 192.168.1.1
MAC: AA:AA:AA:AA:AA:AA MAC: CC:CC:CC:CC:CC:CC MAC: BB:BB:BB:BB:BB:BB
| | |
| <--- Gratuitous ARP Reply ---| |
| "192.168.1.1 is at | |
| CC:CC:CC:CC:CC:CC" | |
| |--- Gratuitous ARP Reply -----> |
| | "192.168.1.50 is at |
| | CC:CC:CC:CC:CC:CC" |Attack Flow:
- Attacker continuously transmits unsolicited ARP reply packets to Victim asserting that the Gateway IP has the Attacker's MAC.
- Attacker transmits ARP reply to Gateway asserting that the Victim IP has the Attacker's MAC.
- Both victim and gateway overwrite their internal ARP tables without verification (stateless protocol flaw).
- All outbound and inbound traffic routes through the attacker's network interface.
Python Scapy Implementation:
1from scapy.all import Ether, ARP, sendp2import time3
4def arp_spoof(target_ip, target_mac, spoof_ip):5 """Sends forged ARP reply to poison ARP cache."""6 # op=2 signifies ARP Reply (is-at)7 packet = Ether(dst=target_mac) / ARP(op=2, pdst=target_ip, hwdst=target_mac, psrc=spoof_ip)8 sendp(packet, verbose=False)9
10print("ARP Spoofing simulation ready (Requires Scapy + Root privileges).")The Chinese Wall (Brewer-Nash) Security Model for Commercial Conflicts of Interest
Brewer-Nash Chinese Wall Formalism (1989)
1. Entity Hierarchy:
- Company Datasets (CDs): Files belonging to an individual corporation (e.g., Bank of Baroda).
- Conflict of Interest (COI) Classes: Datasets of companies in direct competition with each other (e.g., \{ Bank A, Bank B, Bank C \}).
2. Dynamic Access Rules:
- A subject s is allowed access to object o if and only if:
- o is in the same Company Dataset that s has previously accessed, OR
- o belongs to an entirely different Conflict of Interest class.
- Result: The wall is dynamic. Before the analyst opens any file, they have access to all companies. The moment they open their first document for Bank A, the 'wall drops' permanently barring them from ever opening records for Bank B or Bank C.
Important Exam Points & Quick Revision
Examiners frequently ask: Bell-LaPadula vs Biba comparison table (10 marks Section C), MitM ARP poisoning mechanics, and DDoS SYN flood explanation.
100% left on this page — finishing it closes the gap for Classes of Security Attacks & Security Models.
Classes of Security Attacks & Security Models still counts as a weak topic until you finish this note and answer its questions.
Practise this unitTest Your Understanding
Now that you've read through these notes, practice unit MCQs to identify weak points and solidify your learning before exams.