← WA Computer Science ATAR Unit 2

Penetration test phases

The ordered stages of a penetration test: planning, reconnaissance, scanning, gaining access, maintaining access, then reporting, with clean-up of any changes made.

Understanding Penetration test phases in WA Computer Science ATAR Unit 2

What it does: The gaining access (exploitation) phase uses a vulnerability found earlier in scanning to break in, which this call represents. Clean-up follows maintaining access. It removes anything the tester added so the system is left as it was, and it is recorded in the report. Planning always comes first. The tester and client agree on scope, targets and permission before any testing starts. Reconnaissance is gathering information about the target. It is often passive and does not break into anything. Scanning actively probes the target to find open ports, live hosts and possible vulnerabilities. Each phase builds on the one before it. You must know the target (reconnaissance) before you can scan it, and you report last.

Common mistakes: Scanning is phase 3. Reporting must come last, after access has been gained and maintained, so line 3 should be '3 scanning'. Reconnaissance only gathers information about the target. Exploiting a server is gaining access, which comes later. Line 2 should be 'recon: search_public_info(t)'.

Class: _____________________  ·  Name: _____________________  ·  Date: _________

Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.

This module's key terms are also in a printable crossword (Modules 125–266) and word search (Modules 28–266).

Take this worksheet further — free with Cloodit

Each concept is reinforced from every angle — learned, then applied, then tested.

Learning
Duo
Which phase of a penetration test comes first?
Scanning: look for open portsPlanning: agree the scope and rules
Matches
phases = [scanning, planning, reconnaissance, gaining access, reporting]
↓
The phases are out of order and maintaining access is missing. Planning must come first, then reconnaissance, then scanning.
Applying
Meanings
Term
penetration test phases
Meaning
The ordered stages of a penetration test: planning, reconnaissance, scanning, gaining access, maintaining access, then reporting, with clean-up of any changes made.
Practice
1 PLAN: agree scope and get approval
Testing
Gaps
2.
Check Answer
Spots
22 reconnaissance
33 reporting

Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.

The 'Kangaroo Rat' badge — Speed Typer, one of Cloodit's 106 collectible badges
Students earn collectable badges

Over 100 of them, across seven natural biomes.

Study Buddy
Students build a real study resource

Turns their work into revision material ready for Flash Cards and Exam study.

Diamond Dash — one of Cloodit's live, competitive Sprint games
Students lock in with Sprints

Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.

A Cloodit certificate of achievement, ready to personalise and print
Custom printable certificates

Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.

Quick Questions

1. Which phase of a penetration test comes first?
A. Planning: agree the scope and rules ✓
B. Scanning: look for open ports
Planning always comes first. The tester and client agree on scope, targets and permission before any testing starts.
2. A tester looks up a company's public website and staff names, without touching its systems. Which phase is this?
A. Reconnaissance ✓
B. Gaining access
Reconnaissance is gathering information about the target. It is often passive and does not break into anything.
3. A tester runs a tool to find open ports and services on the target network. Which phase is this?
A. Scanning ✓
B. Reporting
Scanning actively probes the target to find open ports, live hosts and possible vulnerabilities.
4. Which order of phases is correct?
A. Planning, scanning, reconnaissance, reporting, gaining access, maintaining access
B. Planning, reconnaissance, scanning, gaining access, maintaining access, reporting ✓
Each phase builds on the one before it. You must know the target (reconnaissance) before you can scan it, and you report last.
5. A tester uses a vulnerability found in scanning to log in to a server. Which phase is this?
A. Reconnaissance
B. Gaining access (exploitation) ✓
Gaining access is where the tester exploits a vulnerability to get into the system, to show that it can be done.

Match the Pairs

nmap -sV 192.168.1.10 → Scanning phase: probes a target to find open ports and the services running on them
whois example.com.au → Reconnaissance phase: gathers public information about the target, such as who owns the domain
Gaining access: the tester exploits a weakness found during scanning to get into the system → exploit(target, vulnerability)
Cleaning up: the tester removes test accounts and files and reverses changes made during the test → delete_account("test_user")
phases = [scanning, planning, reconnaissance, gaining access, reporting] → The phases are out of order and maintaining access is missing. Planning must come first, then reconnaissance, then scanning.
run_exploit(target) write_scope_and_permission() → The exploit is run before planning. Scope and written permission must be agreed in the planning phase, before any testing starts.

Key Term

penetration test phases
The ordered stages of a penetration test: planning, reconnaissance, scanning, gaining access, maintaining access, then reporting, with clean-up of any changes made.

Fill in the Blanks

1. 1. planning 2. reconnaissance 3. scanning
Hint: Type the phase that gathers information about the target, straight after planning.
2. 2. reconnaissance 3. scanning - find open ports 4. gaining access
Hint: Type the phase that probes the target for open ports and services.
3. 4. gaining access - exploit a vulnerability
Hint: Type the kind of weakness found during scanning that the tester now exploits.
4. 4. gaining access 5. maintaining access - stay in 6. reporting
Hint: Type the phase that comes after getting in and before the final write-up.
5. 5. maintaining access 6. reporting - findings and fixes clean up any changes made during the test
Hint: Type the final phase, where results and recommendations are written up.

Spot the Error

Question 1
A 1 planning
B 2 reconnaissance
C 3 reporting
D 4 gaining access
E 5 maintaining access
F 6 reporting
Line C — Scanning is phase 3. Reporting must come last, after access has been gained and maintained, so line 3 should be '3 scanning'.
Question 2
A plan: get_written_approval()
B recon: exploit_server(t)
C scan: find_open_ports(t)
Line B — Reconnaissance only gathers information about the target. Exploiting a server is gaining access, which comes later. Line 2 should be 'recon: search_public_info(t)'.
Question 3
A 1 plan: agree scope in writing
B 2 recon: look up public info
C 3 scan: crack a password
D 4 gain access: use a weakness
Line C — Scanning finds open ports and running services. Cracking a password is an attempt to gain access, which is phase 4. Line 3 should be '3 scan: find open ports'.
Question 4
A recon(target)
B scan(target)
C gain_access(target)
D plan(scope)
E clean_up(target)
F report(findings)
Line D — Planning is the first phase, where scope and permission are agreed. It cannot happen after gaining access. Line 4 should be 'maintain_access(target)'.
Question 5
A # Phase 3: scanning
B whois 10.0.0.5
C # lists open ports and services
Line B — Scanning uses a tool such as nmap to probe the target for open ports and services. whois only looks up registration details, which is reconnaissance. Line 2 should be 'nmap -sV 10.0.0.5'.

Student with a class code? Join your class →