Guide · Agent skill
How to use the USB Device History Analyzer agent skill
Updated · written with AI from the project's own documentation and checked against our catalogue data
The analyzing-usb-device-connection-history skill is a set of instructions and a Python script that lets an AI agent help a digital forensics investigator reconstruct which USB storage devices were connected to a Windows computer, when, and what drive letters they received. It is written for investigators examining removable media on a disk image, not for live monitoring. After reading this guide you will know how to install the skill, how to ask for help with a natural request, and what you need in place before the agent can parse anything.
Quick start
- 1Download and unzip. Download the skill ZIP from this page and unzip the analyzing-usb-device-connection-history folder into ~/.claude/skills/ or your project's .claude/skills/ directory.
- 2Gather evidence. Mount your forensic image read-only, or collect the SYSTEM, SOFTWARE and NTUSER.DAT hives plus setupapi.dev.log and event logs into a case folder.
- 3Install Python dependencies. Make sure Python 3 and the regipy library are available, since scripts/agent.py depends on regipy.
- 4Ask in plain language. Describe the investigation and point the agent at your case folder, for example asking for a list of USB storage devices with first and last connection times.
- 5Parse registry artifacts. Let the agent read the USBSTOR key, MountedDevices and MountPoints2 to collect device identifiers, drive letters and user volume access.
- 6Correlate logs. Have the agent match setupapi.dev.log entries and event log records against the registry results to build a timeline.
- 7Review and document. Check each timestamp against a second artifact and record your findings for the case.
What is an agent skill and what does this one do?
An agent skill is a folder containing a SKILL.md file and optional scripts and reference documents. When the skill is installed, the agent can load these instructions when a request matches the skill's description, so it follows a documented workflow instead of improvising.
This skill correlates three kinds of Windows artifacts: the USBSTOR and MountedDevices registry keys, Windows Event Logs, and the setupapi.dev.log file. Together they let the agent work out first and last connection timestamps for each device and the drive letters assigned to them.
- Copy registry hives (SYSTEM, SOFTWARE, NTUSER.DAT) and logs out of a mounted forensic image
- Parse the USBSTOR key to list device vendor, product, revision, serial and friendly name
- Parse MountedDevices to map drive letters to USB devices or fixed disks
- Read MountPoints2 in NTUSER.DAT to see which user accessed which volumes
- Match setupapi.dev.log install entries and event log records to build a timeline
How do you install the USB Device History Analyzer skill?
Download the ZIP file from this page and unzip it. You can install the skill in one of two places. For a personal setup for all your projects, unzip it into ~/.claude/skills/ so the folder analyzing-usb-device-connection-history sits inside that directory. For a single project, unzip it into the project's .claude/skills/ folder instead.
If you use the Claude apps rather than a local setup, you can upload the skill instead. Go to Settings, then Capabilities, then Skills, and upload the skill there.
- Personal install: ~/.claude/skills/analyzing-usb-device-connection-history/
- Project install: .claude/skills/analyzing-usb-device-connection-history/ inside your project
- Claude apps: Settings → Capabilities → Skills → upload
What do you need before you start?
The skill assumes you already have forensic evidence. It does not create images or collect artifacts from a live machine. You need a forensic image or already-extracted registry hives and event logs from a Windows system, and you need Python 3 with the regipy Python library, which scripts/agent.py uses.
You also need a working knowledge of USB identifiers such as vendor ID, product ID and serial number. The source names optional tools you may use alongside the skill: USBDeview, USB Forensic Tracker and RegRipper.
- Python 3
- regipy Python library (used by scripts/agent.py)
- SYSTEM, SOFTWARE and NTUSER.DAT hives, from a forensic image or extracted copies
- setupapi.dev.log and Windows event log files such as System.evtx
- Optional: USBDeview, USB Forensic Tracker or RegRipper
How do you trigger the skill with a natural request?
You do not need special syntax. Describe the investigation in plain language and mention the artifacts you have. The agent should match the request to the skill's description, which covers removable media usage, device provenance and timelines for suspected data exfiltration.
Be specific about the case: say what evidence folder you have, whether you are working from a disk image or extracted hives, and what question you need answered. Include the time window if you have one.
- "Using the extracted SYSTEM and NTUSER.DAT hives in my case folder, list every USB storage device and when each was first and last connected."
- "Map the drive letters in MountedDevices to USB devices and tell me which were removable media."
- "Build a timeline from setupapi.dev.log and the System event log for suspected data exfiltration on this workstation."
- "Check which user accounts accessed each USB volume using MountPoints2."
What does a typical workflow look like?
The source workflow has four steps. First, mount a forensic image read-only and copy the relevant hives and logs into a separate case folder. Second, parse the USBSTOR key in the SYSTEM hive, using the active ControlSet from the Select key. Third, read MountedDevices and the per-user MountPoints2 keys. Fourth, extract install timestamps from setupapi.dev.log and event IDs from the event logs, then compare them with the registry results.
Expect the agent to write results such as a usb_devices.json file in the analysis folder. Review every timestamp yourself, because the source notes that registry key timestamps reflect last write times and need correlating with other artifacts.
mount -o ro,loop,offset=$((2048*512)) /cases/case-2024-001/images/evidence.dd /mnt/evidenceWhat safety and privacy points should you know?
This skill runs scripts. The SKILL.md workflow and the bundled scripts/agent.py read sensitive registry data, including user activity and device history. The skill does not use the network, according to its listing. Only examine systems you are authorised to investigate.
The skill is for analysing artifacts after the fact. It does not monitor or block USB devices, and it targets Windows artifacts only, so it will not help with Linux or macOS systems. Mount evidence read-only, as the source example does with the ro option, to avoid altering it.
- Use only on systems you have authorisation to examine
- Mount images read-only (the source uses mount -o ro)
- Review the scripts before running them on evidence
- Keep your case folder separate from the original image
What tips help you get reliable results?
Treat registry key last-write times as evidence to corroborate, not as proof on their own. Cross-check the setupapi.dev.log install times, the event log records and the MountedDevices entries before drawing conclusions. Note the ControlSet the skill selects from the Select key so your results are reproducible.
If a file is missing, such as the DriverFrameworks-UserMode event log, the source copies those files with error suppression, so check which artifacts actually exist in your image before building a timeline.
- Corroborate every timestamp with a second artifact
- Record which ControlSet and hive files you used
- Keep the original evidence unchanged and work on copies
- Document each step for your case notes
What people use it for
- Reconstructing which USB drives were plugged into a workstation during a suspected data-exfiltration incident
- Building a timeline of removable media use during an insider threat investigation
- Checking whether staff followed a removable media policy during a compliance audit
- Mapping drive letters to specific USB devices to link files on a copied volume to a device
- Identifying which user account accessed a given USB volume using MountPoints2
Frequently asked questions
How do I install the USB Device History Analyzer agent skill?
Download the ZIP from this page and unzip it into ~/.claude/skills/ for a personal install, or into a project's .claude/skills/ folder for one project. If you use the Claude apps, go to Settings, then Capabilities, then Skills, and upload it there.
What do I need to run this skill?
You need Python 3, the regipy Python library, and Windows evidence such as SYSTEM, SOFTWARE and NTUSER.DAT hives, setupapi.dev.log and event log files. The source also references USBDeview, USB Forensic Tracker and RegRipper as optional tools.
Is the USB Device History Analyzer skill free?
The skill is listed under the Apache-2.0 licence. The source does not state any price, so check the repository licence file for the terms that apply to your use.
Does this skill monitor or block USB devices in real time?
No. It only analyses artifacts after the fact, from a disk image or extracted files. It does not provide live monitoring or blocking of USB devices.
Does it work on Linux or macOS systems?
No. The artifacts it parses, such as the registry keys and Windows event logs, are Windows-specific, so the skill is for Windows systems only.
Does the skill send data over the network?
According to its listing, the skill does not use the network. It does run scripts and reads sensitive registry data, so review the scripts and use it only on systems you are authorised to examine.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
This skill suits forensic analysts, incident responders and compliance staff who already have Windows evidence and want an agent to help parse USB artifacts and build a timeline. It is not a good choice if you need live USB monitoring or blocking, or if your evidence comes from Linux or macOS machines.
Download the skill