In this section

0.5 Running the Case

Module 0

Introduction

The evidence you analyze in this course comes from a case you plant yourself. The lab pack is a set of PowerShell scripts that turn the course VM into each of Northgate Engineering's three Windows hosts in turn, carrying out the intrusion on each so that the artifacts are real: written by Windows, in the places Windows writes them.

This lesson explains how the runs work, what you do during each, and why they happen when they do. You will play the hosts in Module 2.

Three runs on one VM Run 1: NGE-WS-114 you sign in as l.brennan Run 2: NGE-WS-031 you connect over RDP Run 3: NGE-FS-01 the script does it all Evidence drive: three collections Revert to clean before each run. The collections, not the VM, are what you keep.

By the end of this lesson you can:

  • Describe what the lab pack does and which script you run for each part of a host.
  • Explain when each host is played and why it is collected before the VM is reverted.
  • Carry out each host's run, including the parts that happen in a case user's session.
  • State how your evidence will differ from the course's reference output, and where the lab differs from the case.
1

What the Lab Pack Is

understand: four scripts and two files

The lab pack is four PowerShell scripts and two asset files in a single download. One script plants a host, one carries out the steps that must happen inside a case user's own session, one holds the names and helpers the other two share, and one removes the case if you have no snapshot to revert to.

The assets are the decoy remittance PDF Laura Brennan opens and the archive later copied to removable media.

Listed from the evidence drive, the pack holds seven files:

PS C:\> (Get-ChildItem E:\kape-ez-tools-lab-pack -Recurse -File).Name
Deploy-Case.ps1
Invoke-UserActivity.ps1
NGE-Case.common.ps1
README.md
Reset-Case.ps1
Q1_designs.tar
Remittance_Advice_0310.pdf

Nothing in the pack is malware. The attacker's tools in the case are copies of programs that ship with Windows, renamed: the shortcut launches a renamed cmd.exe, the payload is a renamed whoami.exe, and the archiver on the file server is a renamed tar.exe.

That is how the case stays harmless while producing the same evidence a real intrusion would: a program running from an unusual folder under an unusual name is exactly what the execution artifacts in Module 5 record.

The lab pack plants the case with renamed Windows programs, so the evidence is real and nothing harmful ever runs.

You can read every line of the scripts before you run them, and you should. They are written to be read, with a comment on each step naming the case timeline step it carries out, so the script is also a record of what happened on each host.

When a later lesson asks why a particular record exists, the answer is always a step you can find in the script and in the case timeline. Reading the script is not cheating: an investigator never has the attacker's script, but a student who knows what was done can concentrate on learning where each action left its trace, which is the skill the course is teaching.

2

When Each Host Is Played

understand: collect before you revert

You play the hosts in Module 2's exercise, not now. The reason is the snapshot cycle from 0.4: one VM plays three hosts by reverting to clean between them, and reverting throws away everything on the VM's disk. Each host therefore has to be collected with KAPE before the VM is reverted for the next one, and KAPE is installed in Module 1 and taught in Module 2.

When to play the hosts
Play all three hosts now, in Module 0
Play each host in Module 2's exerciseKAPE is installed in Module 1 and taught in Module 2; a host has to be collected before you revert.
Play a host, revert, collect later
Play a host, collect it, then revertReverting first throws the evidence away.
Keep the VM as it is after Module 2
Work from the three collections from Module 3 onThe collections are what you analyze; the VM is only needed to rerun a host.
Collect before you revert, every time.

So the order through the start of the course is fixed. In this module you get the pack onto the evidence drive and learn what the runs do. In Module 1 you install KAPE and the EZ Tools onto the evidence drive.

In Module 2's exercise you play WS-114 and collect it with gkape, KAPE's graphical front end, then revert and play WS-031 and collect it from the command line, then revert and do the same for FS-01. From Module 3 onward you work from those three collections.

Play each host in Module 2's exercise and collect it before reverting: the collection is the only part of a run you keep.

After Module 2 you only need the VM again if a collection turns out to be incomplete, in which case you revert, play that host again and collect it again. Keep the three collections and their ground-truth files together on the evidence drive for the whole course, one folder per host.

Every exercise from Module 3 to the capstone report reads them, and losing one means replaying that host, which costs an hour or two and gives you a collection with different times from the one your earlier notes describe.

3

Getting the Pack Into the VM

apply: onto the evidence drive

Download the pack on your own computer, then copy it onto the evidence drive, so the VM can reach it after every revert. If your evidence drive is a shared folder, extract the pack into it from your computer.

If it is a second virtual disk, copy the pack in once, by a host-to-guest copy or a temporary shared folder, then put the setting back the way 0.4 left it. Either way the pack lives on the evidence drive, not the VM's own disk, so a revert does not remove it.

Where the pack and its records live
E:\kape-ez-tools-lab-packthe copy you keep; every run starts hereevidence drivesurvives revert
C:\NGE-Lab\packthe copy Deploy-Case makes for the case accounts to readVM diskgone at revert
C:\NGE-Lab\state-<host>.txtthe stage the run has reachedVM diskgone at revert
C:\NGE-Lab\ground-truthwhat each step did and when, in UTC; copy it outVM diskcopy before revert

When Deploy-Case runs, it copies the pack to C:\NGE-Lab\pack inside the VM, because the scripts that run in a case user's session need it at a path every account can reach. That copy is on the VM's own disk and disappears with the revert, which is intended: each host starts with a fresh copy taken from the evidence drive.

Keep the pack on the evidence drive and start each run from there: the script copies what it needs into the VM, and the revert removes it.

Do not unblock or change the scripts to make them run. The command in the next section runs them as they are, and a script you have edited no longer produces the evidence the course's reference output and model answers describe.

4

Running Deploy-Case

apply: as administrator, from the pack folder

Every run starts the same way. Sign in to the VM with your own account, open PowerShell as administrator, change to the pack's folder on the evidence drive and run Deploy-Case.ps1 with the host you are playing. The script checks that it is running as administrator and on a virtual machine, and stops if either is not true.

PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-WS-114

=== Next ===
  The VM restarts now as NGE-WS-114.
  After it restarts, sign in as l.brennan (password NGE-Lab-2026!).
  In that session open PowerShell (not as administrator) and run:
    powershell -ExecutionPolicy Bypass `
      -File C:\NGE-Lab\pack\Invoke-UserActivity.ps1 -CaseHost NGE-WS-114

The -ExecutionPolicy Bypass on the command line lets this one PowerShell process run the unsigned script without changing the machine's execution policy, which a case host would not have changed.

The -CaseHost parameter takes one of the three host names, and the script tells you what to do next in a block headed Next at the end of each stage. Read that block every time before the VM restarts: it is the only place the script tells you what it expects of you before the next stage.

Run Deploy-Case as administrator from the pack folder with the host's name, and read the Next block before the restart: it says what to do next.

If you miss the message, run the same command again after the restart. The script works out where it stopped and repeats the instructions for that stage.

The stage you are on is also recorded in the ground-truth file as each step completes, so if you lose track entirely, the last line of that file tells you which step ran most recently. You can open it to check progress without spoiling anything, because it records what the script did rather than what the investigation should conclude.

5

Stages and Restarts

understand: the same command each time

Each host takes several stages, with a restart between most of them, because some of the evidence is only written at a restart and some of the activity has to happen in a different account's session. You do not choose the stage. After each restart you run exactly the same Deploy-Case command again, and the script carries on from where it stopped.

After the first stage on WS-114 and its restart, the state file holds the stage the run has reached:

PS C:\> Get-Content C:\NGE-Lab\state-NGE-WS-114.txt
1

The script keeps track with a small state file for each host in C:\NGE-Lab. That is also how it protects the snapshot cycle.

If you start a run for one host on a VM that has already played another, it finds the other host's state file and refuses, with a message telling you to revert to the clean snapshot first. Two hosts' evidence on one disk would make every exercise that reads that collection unreliable.

After each restart run the same command again: the script knows the stage, and it refuses to play a second host on an unreverted VM.

If a stage is waiting on something you have not done yet, such as the user activity, it says so and stops without changing anything, so running the command early does no harm.

6

Run 1: NGE-WS-114

apply: the finance workstation

The first run plays Laura Brennan's finance workstation. The first stage renames the VM to NGE-WS-114, creates her account, makes sure Prefetch is recording, places the attacker's files and restarts. You then sign in as l.brennan and run Invoke-UserActivity.ps1 in her session, in an ordinary PowerShell window, not as administrator, because a standard user's actions are what the case needs.

Run 1: NGE-WS-114PowerShell
01Plant the host
As administrator, from the pack folder. The VM restarts as NGE-WS-114.
PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-WS-114
02Be Laura Brennan
Sign in as l.brennan and run the user activity in her session, not as administrator.
PS C:\Users\l.brennan> powershell -ExecutionPolicy Bypass -File C:\NGE-Lab\pack\Invoke-UserActivity.ps1 -CaseHost NGE-WS-114
03Finish the host
Sign out, sign in as labadmin and run Deploy-Case again; after the restart, once more.
PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-WS-114
Still to do: collect the host with gkape in Module 2, copy out the ground truth, then revert.

The user activity is where the intrusion happens. It creates her Downloads\Supplier folder with the remittance shortcut and decoy PDF, marked as downloaded from the internet, opens the folder in Explorer, launches the shortcut the way a double-click would, runs the payload twice more, then writes and deletes the inert credentials note.

When it finishes you sign out, sign back in with your own account and run Deploy-Case again, which runs the inventory scan and restarts. One more run of the command after that tells you the host is planted.

On WS-114 the intrusion runs in Laura Brennan's own session: sign in as l.brennan and run the user activity there, not as administrator.

The script tells you to collect this host with gkape. That is the first part of Module 2's exercise. Do not sign in as l.brennan again after the user activity has finished. Each sign-in adds logon events and profile activity to her account, and the model answers describe one interactive session, the one in which she opened the remittance.

If you sign in again by mistake, the evidence is still usable, but your logon counts will not match and you should note why.

7

Run 2: NGE-WS-031

apply: the administrator workstation over RDP

The second run plays Kieran Ashworth's IT administrator workstation, and it is the one where you do the most. Revert to clean first. The first stage renames the VM, creates k.ashworth and adm.kashworth, enables Remote Desktop and sets up the Engineering share the intruder browses.

After the restart you connect to the VM over Remote Desktop from your own computer, signing in as adm.kashworth, because the case's intruder reached this host over RDP with that account.

Run 2: NGE-WS-031PowerShell and Remote Desktop
01Revert and plant the host
Revert to clean first. The VM restarts as NGE-WS-031 with Remote Desktop enabled.
PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-WS-031
02Connect from your own computer
On your computer, to the VM's address; sign in as adm.kashworth.
PS C:\Users\you> mstsc /v:<VM address>
03Be the intruder
In the RDP session, PowerShell as administrator. Pass a USB stick through first if you have one.
PS C:\Windows\system32> powershell -ExecutionPolicy Bypass -File C:\NGE-Lab\pack\Invoke-UserActivity.ps1 -CaseHost NGE-WS-031
04Finish the host
Sign out of RDP, sign in at the VM as labadmin, run Deploy-Case again, and once more after the restart.
PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-WS-031
Still to do: collect the host from the command line in Module 2, copy out the ground truth, then revert.

That connection is what makes the remote access evidence real: the logon records, the RDP session events, the profile created at the first remote session.

Inside the RDP session you run the user activity as administrator, which plants the Run value, the scheduled task and the service, browses the share, and copies the archive to removable media. If you have a USB stick, pass it through to the VM before that step; if not, the script uses a virtual disk instead.

On WS-031 connect over Remote Desktop from your own computer as adm.kashworth: the RDP evidence is real only because you made a real connection.

When the activity finishes, sign out of the RDP session, sign in at the VM with your own account and run Deploy-Case twice more, once before and once after its restart. If the Remote Desktop connection fails, the cause is almost always the network from 0.4: your computer cannot reach the VM's address.

Check it from your computer before suspecting the script, which has already enabled Remote Desktop and allowed adm.kashworth to use it. Do not connect from inside the VM to itself as a shortcut, because a connection that never leaves the machine does not produce the evidence the case describes.

8

Run 3: NGE-FS-01

apply: the file server

The third run plays the engineering file server, and you do the least. Revert to clean again. The first stage renames the VM, creates adm.kashworth, creates and seeds the Engineering share with the design files, turns on share auditing and restarts. When you run the command again, the script carries out the whole of the intruder's work on the server in one stage.

The first stage ends by telling you what comes next, as every stage does:

PS E:\kape-ez-tools-lab-pack> powershell -ExecutionPolicy Bypass -File .\Deploy-Case.ps1 -CaseHost NGE-FS-01

=== Next ===
  The VM restarts now as NGE-FS-01.
  Sign in with your own admin account and run this command again.

That stage maps the share with adm.kashworth's credentials, drops the renamed archiver into C:\Windows\Temp, copies twelve design files into a staging folder and renames them, archives them, deletes the staging folder, sets the archive's timestamps back, and clears the Windows PowerShell event log.

You do not sign in as a case user at any point, because on the file server the intruder never had an interactive session: everything arrived over the network with a stolen account.

On FS-01 the script does the intruder's work itself, because the intruder only ever reached the server over the share with a stolen account.

After the inventory scan and a final restart, the script tells you to collect the host from the command line. That is the last collection of Module 2's exercise.

9

Why the Script Restarts

understand: evidence written later

The restarts are not housekeeping. Two of the execution artifacts the course examines are not written at the moment a program runs. Amcache is populated by the Microsoft Compatibility Appraiser, a scheduled task that inventories programs on the machine, and on a real host it runs on its own schedule. ShimCache entries are held in memory and written to the SYSTEM hive when Windows shuts down.

What the last step of each host's run writes
The inventory taskthe Microsoft Compatibility Appraiser, run by the scriptlast step
Amcache.hvengsync.exe inventoried, with its SHA-1; before the task, no entry yetwrittenM5
The restartRestart-Computer, at the end of the runlast step
SYSTEM hive, AppCompatCacheShimCache written from memory to the registrywrittenM5
The computer namethe rename to NGE-WS-114 takes effectapplied

So at the end of each host's activity the script runs the Appraiser itself and then restarts, which writes ShimCache. Without those two steps, a collection taken straight after the activity would be missing entries an investigator would find on a real machine that had been running for a while.

The restarts also make the computer rename take effect, and a case user's first sign-in creates the profile that holds their own registry hive.

The script runs the inventory scan and restarts because Amcache and ShimCache are written later than the activity they record.

This timing is itself evidence, and Module 5 teaches it: an entry's time in one of these artifacts can describe when it was written rather than when the program ran.

10

The Case Accounts

apply: names, rights and the password

The script creates the case's accounts on each host as local accounts. In the case they are accounts in the NORTHGATE domain; in your lab there is no domain, so each host gets its own local copy of the accounts it needs. That is why adm.kashworth on WS-031 and adm.kashworth on FS-01 in your evidence have different security identifiers, which 0.3 explained.

On WS-031, both of Kieran Ashworth's accounts exist with the names and full names the case gives them:

PS C:\> Get-LocalUser -Name k.ashworth, adm.kashworth | Format-Table Name, FullName

Name          FullName
----          --------
k.ashworth    Kieran Ashworth
adm.kashworth Kieran Ashworth (admin)

Every case account has the same lab password, printed by the script when you need it. It exists so you can sign in and connect over RDP as the case users, and it should never be used anywhere outside the course VM. Your own account, the one you installed Windows with, stays on each host alongside the case accounts and is the one you run Deploy-Case and KAPE from.

The case accounts are local to each host and share one lab-only password: your own account stays on the machine as the one you run the scripts from.

You will see your own account in the collections too, as the administrator who ran the scripts and the collection. That is expected, and 0.6 explains how to tell it apart from the case. Choosing a plain name for your own account at installation pays off here.

An account called labadmin or student is easy to set aside when you read a list of profiles or logons; an account named after you puts your name in every finding you write, which is the problem 0.4 set out to avoid.

11

Your Evidence Will Differ

understand: what matches the reference and what does not

The course shows expected output from a reference run of the same scripts on clean VMs. Your output will match it in structure and differ in detail. Every timestamp is the time you ran the step, every SID is generated by your VM, and file system details such as entry numbers and volume serials depend on your disk.

Answering from your own evidence
Copy the time from the course's reference output
Read the time from your own collectionEvery timestamp in your evidence is the moment you ran the step.
Quote the SID shown in the lesson
Quote the SID in your own evidenceYour VM generated its own.
Order the hosts as the case tells the story
Order your records as your runs happenedYour hosts were played in run order; the case orders them by the intrusion.
Structure matches the reference; every time and identifier is your own.

The exercises are written around what does not differ: which files, keys, tasks, services and accounts exist, how many times a program ran, which event came before which. Where a question turns on time, the model answer tells you to check your own run's times in the ground-truth file the script writes.

There is also one ordering difference to keep in mind. In your lab the hosts happen in the order you play them, WS-114, then WS-031, then FS-01, while in the case the archive on FS-01 was made before it was copied to USB on WS-031.

Expect your output to match the reference in structure and differ in every timestamp and identifier: the exercises check what the scripts guarantee.

Module 9, which builds one timeline across the hosts, comes back to that ordering difference and how to read it.

12

Where the Lab Differs From the Case

understand: stated limits

A lab built from one Windows 11 VM cannot reproduce every detail of a company network, and the course says where it does not rather than pretend. There are four places, and each lesson affected states the difference where it matters.

Where the lab differs from the case

Stated wherever it matters

The share on WS-031

Local to the VM, so the network path in ShellBags is real but the SMB session events are not

FS-01

Windows 11 with a share, not Server; Prefetch is off by default on Server, which Module 5 covers

Removable media

A virtual disk if you have no USB stick to pass through: fewer records, named in Module 8

NGE-DC-01

Not built; its collection is shown in the course in Modules 2 and 7

On WS-031 the Engineering share is on the VM itself, named to look like the file server, so browsing it writes a genuine network path into the ShellBags while the server-side session records exist only in the case.

FS-01 runs on Windows 11 rather than Windows Server, which matters for Prefetch: Windows 11 normally records it, Server has it off by default, and the script makes sure it is on for the hosts that need it. Removable media evidence from a virtual disk lacks some of the records a real USB stick leaves. And the domain controller is not built at all.

The lab differs from the case in four stated places: the share on WS-031, Windows 11 as the file server, removable media without a stick, and the domain controller.

None of these changes what the exercises ask. They change which records you will find in your own collections, and the lessons name the records each time. Treat these limits the way you would treat the limits of any real collection.

Investigators rarely get every artifact they want: a log has rolled over, a machine was rebuilt, a disk was encrypted. Stating plainly what the evidence cannot show, and why, is part of writing a finding that holds up, and Module 9 makes that a habit.

13

Finishing a Host

apply: collect, copy, revert

When the script says a host is planted, three things happen in a fixed order. Collect the host with KAPE to the evidence drive, as Module 2's exercise describes. Copy the ground-truth file for that host from C:\NGE-Lab\ground-truth onto the evidence drive beside the collection. Then revert the VM to the clean snapshot.

Finishing a host Collect KAPE, to the evidence drive Copy ground truth beside the collection Revert to clean before the next host In this order. Reverting first throws away the evidence; collecting is the only way it leaves the VM.

The order matters because the revert is irreversible. If you revert before collecting, the host's evidence is gone and the run has to be done again. If you revert before copying the ground-truth file, you lose your own record of when each step happened, which several exercises rely on.

The ground-truth folder is deliberately outside the paths the course's KAPE collections take, so it never appears in your evidence, which is why it has to be copied separately.

Collect, copy the ground-truth file, then revert, always in that order: the revert removes anything not on the evidence drive.

0.6 explains what is in the ground-truth file and when to open it.

Practice

Get the lab pack ready for Module 2.

Do this Get the lab pack ready

In the course VM and on your own computer.

  1. Download the pack on your own computer. From the lab pack download.
  2. Put it on the evidence drive. Extract it into its own folder there, so the VM can reach it after every revert.
  3. Read the script's help in the VM. In PowerShell in the pack folder, run Get-Help .\Deploy-Case.ps1 -Full and read what it says it will do.
  4. Plan the removable media. Decide whether you will pass a USB stick through for run 2, and find your hypervisor's setting for it.
  5. Do not run Deploy-Case yet. You play the hosts in Module 2's exercise, once KAPE is installed, so each can be collected before you revert.
What you should end up with: the lab pack on the evidence drive, the script's help read in the VM, and a decision about the USB stick.

Check your understanding

Answer each question before you read on. Every option explains itself once you choose it, the wrong ones too.

When do you play the three hosts?

Now, in Module 0, so the evidence is ready.
A host must be collected before the revert, and KAPE comes in Modules 1 and 2.
In Module 9, when the timeline is built.
The collections are needed from Module 3 on.
In Module 2's exercise, collecting each host before reverting the VM.
Right. Play, collect, copy the ground truth, revert.
Whenever is convenient, because the VM keeps each host's evidence separately even if you never revert it.
One disk holds one host at a time; the script refuses a second host on an unreverted VM.

Why do you connect to WS-031 over Remote Desktop from your own computer, rather than from inside the VM?

So the logon and session records come from a real remote connection.
Right. A connection that never leaves the machine does not produce the evidence the case describes.
Because the VM cannot run the Remote Desktop client.
It can; that is not the reason.
To keep the run faster.
Speed has nothing to do with it.
Because adm.kashworth is not allowed to sign in at the console of the VM under the lab pack's settings.
The account can sign in locally; the point is the remote session's records.

Why does each host's run end with an inventory task and a restart?

To clear the case from memory before collection.
The restart writes records; it is not a clean-up.
Amcache and ShimCache are written after the activity they record.
Right. Without these steps a collection misses records a long-running machine would hold.
Because KAPE cannot run until the machine has been restarted at least once since the computer was renamed by the script.
KAPE does not depend on a restart.
To apply Windows updates.
Updates are paused in the clean snapshot.

Your WS-114 timestamps are all on the day you ran it, not 10 March 2026. Is something wrong?

Yes: the VM clock was wrong.
The clock was right; you ran the case on your own date.
Yes: rerun the host with the date set back.
Changing the clock would add evidence of its own.
Only if the hours do not match the case calendar, because the scripts reproduce the case's times of day exactly.
The scripts reproduce actions, not times of day.
No: your evidence carries your run's times.
Right. The exercises check structure, and your ground truth checks your times.

Resources

The lab pack's README.md and the comment help in Deploy-Case.ps1 (Get-Help .\Deploy-Case.ps1 -Full) describe the same runs in brief.