BraddCorp Tools

Tools / USB Drive Test

USB Drive Test

A command-line tool that fills a USB volume with verifiable data, reads it back, and tells you whether the drive can actually hold what it claims — catching many counterfeit thumb drives.

MITCLIUSBmacOSearly-stage

What it does

A command-line tool that fills an external USB volume with verifiable test data, reads every byte back, and reports pass or fail. It catches many counterfeit drives that advertise far more space than they actually have.

Features

  • Lists external USB volumes on your Mac and asks you to confirm the target.
  • Writes test files, then checks checksums and patterns on the way back.
  • Reports PASS or FAIL for fake capacity, corruption, or an early write failure.
  • --quick runs a short smoke test; a full run is the legitimacy check.

See it in action

Simulated Two sample runs against pretend volumes. The tool would erase a real disk.

usb-drive-test · sample volumes
$ usb-drive-test --mount /Volumes/EXAMPLE --quickPASS
Volume EXAMPLE  claimed 64 GB
Writing test pattern……  done
Reading checksums……    done
PASS  claimed 64.0 GB, verified 64.0 GB
Quick test only — a full run is the legitimacy check.
$ usb-drive-test --mount /Volumes/BARGAIN1TBFAIL
Volume BARGAIN1TB  claimed 1 TB
Writing test pattern……  failed at 8.0 GB
Device reported a short write, then disconnected.
FAIL  claimed 1024 GB, verified only 8.0 GB
This is the usual counterfeit-capacity pattern.

Set it up

This erases the volume you point it at. Confirm the mount path before you start.

Examples
# Full test on a drive you think is 128 GB
~/usb-drive-test/usb-drive-test --mount /Volumes/KINGSTON --size 128GB

# Fast 1 GB smoke test
~/usb-drive-test/usb-drive-test --mount /Volumes/KINGSTON --quick

# Interactive (pick from list)
~/usb-drive-test/usb-drive-test

Full instructions live in the repository README.

Security

  • A wrong --mount path can destroy data on the wrong disk. Prefer an explicit path after you have looked at the volume name.
  • Do not run as root against raw device names unless you understand them.
  • The tool has no network client and stores no secrets.

Report vulnerabilities to Hello@Braddcorp.com, and read the full SECURITY.md for the threat model and operator hygiene.

Known limitations

Destructive by design

Existing files on the target volume are not preserved.

--quick is not complete

A short write will not catch every counterfeit capacity trick.

Pre-1.0

The current tree is aimed at macOS. Only the main branch is supported.

Changelog

No tagged releases yet. The project is pre-1.0 and only main is supported, so this is the commit history.

Commits

  • db1e766Add MIT license and SECURITY.md (#1)

  • 7427586Add USB drive test binary and README.

Generated at build time from 2 commits on main (db1e766) on 2026-12-06 UTC. Dates are UTC. No requests to GitHub happen when you view this page.

License

MIT, copyright BraddCorp. See LICENSE. Contributions and forks are welcome on GitHub.