Individual skill
analyzing-usb-device-connection-history
Investigate USB device connection history from Windows registry, event logs, and setupapi logs to track removable media usage and potential data exfiltration.
internal/tools/skills/data/digital-forensics/analyzing-usb-device-connection-history/SKILL.md
Source commit d42f381ad34843e71a42658e5c57290c713e85af
What was checked
- Matches the observed repository HEAD
- Yes
- Scanner rules are current
- Yes
- Repository scan complete
- No
- Skill scan complete
- No
- Observed behavior
- Instructions only
- Last checked
- Nov 9, 2026
These are observations at the recorded commit, not a guarantee of safety. Review the source before running it.
Install this skill
Choose an agent in your Stack or copy a command below. Commands fetch the pinned commit and copy only this skill directory. Existing destinations are refused. Copying a command does not install anything.
An install command is unavailable: current rules, complete repository and skill scans, an eligible behavior level and a permitted license are required.
Repository context
- Repository stars (not skill ratings)
- 1,331
- Repository last updated
- Nov 9, 2026
- License
- Apache-2.0
Observed agent integration: No specific integration evidence. Standard SKILL.md installation does not imply verified compatibility.
- cybersecurity Repository topic
- security Repository topic
- bug-bounty Repository topic
- automation Repository topic
- autonomous-pentesting Repository topic
- ai-agent Repository topic
- ai-security Repository topic
- ethical-hacking Repository topic
- golang Repository topic
- penetration-testing Repository topic
- forensics Declared skill tag
- usb-forensics Declared skill tag
- removable-media Declared skill tag
- registry-analysis Declared skill tag
- data-exfiltration Declared skill tag
- device-history Declared skill tag
- data Derived category
Files and excerpt
File metadata and permitted, redacted excerpts come from the recorded scan. Source links are pinned to that commit.
Browse files
Read excerpt
# Analyzing USB Device Connection History
## When to Use
- When investigating potential data exfiltration via removable storage devices
- During insider threat investigations to track USB device usage
- For compliance audits verifying removable media policy enforcement
- When correlating USB connections with file access and copy events
- For establishing a timeline of device connections during an incident
## Detection Gaps & Validation
- **Most-missed artifacts:** USBSTOR alone is incomplete. Also parse the `USB\` key (VID/PID for non-mass-storage and MTP/PTP phones that USBSTOR omits), `MountedDevices`, per-user `MountPoints2`, `SYSTEM\...\DeviceClasses\{GUID}`, the SOFTWARE-hive `...\Windows Portable Devices\Devices` and `EMDMgmt` (volume serial + first/last timestamps), `setupapi.dev.log` (first insert), and `Microsoft-Windows-Partition%4Diagnostic.evtx` (capacity/serial, useful for sizing exfil).
- **First vs last connect, and per-user attribution:** the USBSTOR key LastWrite is only the *last* event for that device - get the *first* connection from `setupapi.dev.log` and per-session connects from DriverFrameworks-UserMode / Partition-Diagnostic event logs. A device in USBSTOR proves it touched the machine, not which user used it - tie it to a user via that user's `MountPoints2` volume GUID.
- **Anti-forensics that defeats this analysis:** registry keys and `setupapi.dev.log` can be deleted or the log rotated/truncated. Recover prior state from Volume Shadow Copies, `SYSTEM.LOG1/2` transaction logs, and RegBack. A wiped USBSTOR with surviving MountPoints2/EMDMgmt entries is itself an indicator.