1.1 What ethical hacking actually is
Ethical hacking is the authorized practice of probing systems, networks, and applications the same way an attacker would, in order to discover weaknesses before a malicious actor does. The word that carries all the weight is authorized. An ethical hacker (also called a penetration tester or offensive security engineer) does exactly what a criminal does technically, but does it with written permission, inside an agreed scope, and produces a report that helps the owner fix the problems.
The value proposition is simple: it is far cheaper to pay a professional to find your weaknesses than to have a breach find them for you. Organizations hire ethical hackers to validate their defenses, satisfy regulators, protect customer data, and build confidence before shipping products.
Three roles that get confused. A penetration tester simulates a real attack against a defined scope to prove exploitability. A vulnerability assessor catalogues and prioritizes weaknesses, usually without exploiting them. A red teamer runs a goal-oriented, stealthy, adversary-emulation campaign (e.g. "reach the payroll database without being detected"). They overlap but the intent and depth differ.
1.2 The CIA triad — the goal of all security
Every control you will ever meet exists to protect one or more of three properties. This is the single most important model in the field.
| Property | Meaning | Example attack against it |
|---|---|---|
| Confidentiality | Information is only seen by those authorized to see it | Data theft, eavesdropping, weak encryption |
| Integrity | Information is accurate and has not been tampered with | Altering a bank transaction, defacing a page, malware injection |
| Availability | Information and services are accessible when needed | Denial-of-service, ransomware, hardware sabotage |
Two further goals are often added to extend the triad:
- Authenticity — you can trust that a message or user genuinely is who it claims to be (defeated by spoofing and impersonation).
- Non-repudiation — a party cannot credibly deny having performed an action (provided by digital signatures and reliable logging).
1.3 The vocabulary you must never mix up
- Asset
- Anything of value worth protecting — data, servers, a domain name, reputation, people.
- Threat
- A potential cause of harm: a hacker group, malware, a disgruntled employee, a flood.
- Threat actor
- The entity behind a threat (a person, group, or nation-state).
- Vulnerability
- A weakness that a threat can use — an unpatched service, a weak password, an untrained user.
- Exploit
- The specific technique or piece of code that takes advantage of a vulnerability.
- Payload
- The part of an attack that performs the intended action after the exploit succeeds (e.g. a remote shell).
- Risk
- The likelihood that a threat exploits a vulnerability, combined with the impact. Informally: Risk ≈ Threat × Vulnerability × Impact.
- Zero-day
- A vulnerability unknown to the vendor, for which no patch yet exists.
- Attack surface
- The total set of points where an attacker could try to enter or extract data.
A memory hook: a threat is the burglar, the vulnerability is the unlocked window, the exploit is the act of climbing through it, the payload is what the burglar does inside, and risk is how worried you should be given both.
1.4 Types of hackers and threat actors
- White hat — authorized, ethical professionals. This is you.
- Black hat — malicious attackers acting illegally for personal gain, disruption, or ideology.
- Grey hat — operate in between; may test systems without permission but without clear malice, often disclosing what they find. Still legally exposed.
- Script kiddie — unskilled actors who run others' tools without understanding them.
- Hacktivist — motivated by a political or social cause (e.g. defacements, leaks).
- State-sponsored / APT — well-funded, patient nation-state groups ("Advanced Persistent Threats") pursuing espionage or sabotage.
- Insider threat — an employee or contractor who misuses legitimate access, whether maliciously or by negligence.
- Cyber-terrorist / organized crime — motivated by fear or, most commonly today, by money (ransomware syndicates).
1.5 Classifying attacks
Attacks are grouped along a few axes:
- Passive vs. active. Passive attacks observe without altering (sniffing traffic, reconnaissance). Active attacks change or disrupt (modifying data, denial-of-service, brute forcing).
- Inside vs. outside. An outsider has no legitimate access; an insider already does.
- By target layer. Operating-system attacks, application-level attacks, misconfiguration attacks, and "shrink-wrap" attacks that abuse default settings in off-the-shelf software.
1.6 The five phases of a hack
Almost every intrusion — and every structured penetration test — follows the same lifecycle. Memorize this order; it structures the rest of the course.
| # | Phase | Attacker goal |
|---|---|---|
| 1 | Reconnaissance | Gather information about the target (passive and active footprinting) |
| 2 | Scanning & Enumeration | Identify live hosts, open ports, services, and extract detailed lists (users, shares) |
| 3 | Gaining Access | Exploit a weakness to get a foothold |
| 4 | Maintaining Access | Establish persistence so the foothold survives (backdoors, scheduled tasks) |
| 5 | Clearing Tracks | Remove evidence to avoid detection (log tampering) — a defender studies this to build better detection |
1.7 Cyber Kill Chain and MITRE ATT&CK
Two industry frameworks describe attacker behaviour in more detail:
- The Lockheed Martin Cyber Kill Chain breaks an intrusion into seven stages: reconnaissance → weaponization → delivery → exploitation → installation → command & control (C2) → actions on objectives. Its power for defenders is that breaking any single link stops the chain.
- MITRE ATT&CK is a continuously updated knowledge base of real-world adversary tactics (the "why", e.g. Privilege Escalation) and techniques (the "how", each with an ID like T1078). Blue teams use it to map their detection coverage; red teams use it to plan realistic emulation.
1.8 Defense-in-depth and security controls
Defense-in-depth means layering independent controls so that no single failure exposes everything — like a castle with a moat, walls, guards, and a locked keep. Controls are categorized two ways:
| By function | By type |
|---|---|
| Preventive — stop an incident (firewall, MFA) | Administrative — policies, training, procedures |
| Detective — spot an incident (IDS, logs, SIEM) | Technical/logical — software and hardware controls |
| Corrective — limit damage and recover (backups, IR plan) | Physical — locks, cameras, guards, fences |
Also worth knowing: deterrent controls (warning banners) and compensating controls (an alternative when the ideal control is impractical).
🛡 Defender's takeaway
- Classify every asset and know which CIA property matters most for it — availability dominates for a payment gateway, confidentiality for medical records.
- Assume breach. Layer controls so detection and response exist even after prevention fails.
- Map your detections to the Kill Chain and ATT&CK so you can see your blind spots, not just your alerts.
1.9 Where the ethical hacker fits
Security teams are often described by colour. Red teams attack. Blue teams defend, monitor, and respond. Purple teaming is the collaborative practice where red and blue share findings in real time so defenses improve faster. A well-rounded professional understands all three — you cannot defend an attack you do not understand, and you cannot responsibly attack without understanding the damage you could cause.

