Lesson 10 of 12
Lab 10 — Malware Analysis
Safely triage a suspicious file using hashes, strings and behaviour — without ever running it on a real machine.
Learn it
Malware is software designed to harm: viruses, worms, trojans, ransomware and spyware.
Analysts never open suspicious files on a normal computer — they use isolated 'sandboxes'.
A file hash is like a fingerprint: the same file always gives the same hash.
Key terms
- Hash
- A fixed-length fingerprint of a file; any change produces a new hash.
- Sandbox
- An isolated environment for safely running suspicious software.
- IOC
- Indicator of Compromise — evidence such as a domain or hash linked to an attack.
- Ransomware
- Malware that encrypts files and demands payment.
- Persistence
- Techniques malware uses to survive a reboot.
Triage 'Invoice_2026.pdf.exe'
A teacher received this attachment. Analyse it step by step.
- 11. Name: Double extension: it is an .exe pretending to be a PDF.
- 22. Hash: SHA-256 matches a known ransomware family in threat-intel databases.
- 33. Strings: Contains 'YOUR FILES ARE ENCRYPTED', a Bitcoin address and the domain pay-decrypt[.]top.
- 44. Sandbox run: It deletes shadow copies, encrypts test files and adds a startup registry key (persistence).
- 55. Network: It contacts 185.220.x.x on port 443 — the command-and-control server.
- 66. Response: Block the hash, domain and IP; search mailboxes for the same email; restore from offline backups.
Hashing a file
pythonimport hashlib
def sha256_of(path):
h = hashlib.sha256()
with open(path, 'rb') as f:
for chunk in iter(lambda: f.read(8192), b''):
h.update(chunk)
return h.hexdigest()
known_bad = {'e3b0c44298fc1c149afbf4c8996fb924...'}
print(sha256_of('sample.bin') in known_bad)Reading the file in chunks and hashing it gives a fingerprint you can compare against lists of known malware — without running it.
Try it
Match the malware type to what it does.
Challenge
Write a malware triage report for 'Invoice_2026.pdf.exe': summary, IOCs, behaviour observed, impact and recommended actions.
Pick whichever way suits you — every mode earns the same bonus XP.
Write at least 40 more characters to submit.
Mark your own work
Guided walkthrough — 0/3 clues revealed
- Clue 1 locked — reveal it only if you get stuck.
- Clue 2 locked — reveal it only if you get stuck.
- Clue 3 locked — reveal it only if you get stuck.
Each clue costs 7 XP (never below 33 XP). You'd earn 65 XP right now.