# hephaest0s/usbkill

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/hephaest0s-usbkill).**

4,570 stars · 515 forks · Python

## Links

- GitHub: https://github.com/hephaest0s/usbkill
- awesome-repositories: https://awesome-repositories.com/repository/hephaest0s-usbkill.md

## Description

usbkill is a physical access defense tool and system monitor that triggers immediate power-off or shutdown sequences when unauthorized USB device changes are detected. It functions as a USB device shutdown trigger and volatile memory wiper designed to prevent forensic data recovery by automating system termination upon hardware tampering.

The tool includes a USB device whitelist manager that ignores trusted hardware to prevent accidental shutdowns during legitimate device usage. It provides anti-forensic data protection by executing destructive commands to erase RAM and swap space before the system shuts down.

The project covers hardware activity monitoring and shutdown automation, allowing for the execution of custom cleanup scripts and sequential command execution immediately before a system power-off.

## Tags

### Security & Cryptography

- [Physical Port Security](https://awesome-repositories.com/f/security-cryptography/security/infrastructure-and-hardware/embedded-and-hardware/physical-security/physical-port-security.md) — Secures physical ports by triggering system shutdown when unauthorized USB devices are connected.
- [Physical Access Defense Tools](https://awesome-repositories.com/f/security-cryptography/security/infrastructure-and-hardware/embedded-and-hardware/physical-access-defense-tools.md) — Provides a security utility that automates system termination upon hardware tampering to prevent forensic recovery.
- [Volatile Memory Wipers](https://awesome-repositories.com/f/security-cryptography/sensitive-data-access-controls/self-destructing-sharing/local-data-wipers/volatile-memory-wipers.md) — Executes destructive commands to erase RAM and swap space before the system shuts down.
- [Volatile Memory Overwriting](https://awesome-repositories.com/f/security-cryptography/volatile-memory-processing/volatile-memory-overwriting.md) — Wipes RAM and swap space with random data to prevent forensic data recovery before power-off.
- [Hardware Device Whitelists](https://awesome-repositories.com/f/security-cryptography/domain-based-access-controls/domain-whitelists/username-whitelists/hardware-device-whitelists.md) — Matches connected device IDs against a trusted list to prevent accidental shutdowns during authorized use.

### DevOps & Infrastructure

- [Shutdown Hooks](https://awesome-repositories.com/f/devops-infrastructure/graceful-shutdowns/shutdown-hooks.md) — Executes designated cleanup binaries and destructive commands as shutdown hooks during system power-off.

### Hardware & IoT

- [USB Device Identification](https://awesome-repositories.com/f/hardware-iot/usb-device-communication/usb-device-identification.md) — Detects and distinguishes USB hardware peripherals to automate security responses and lockdown procedures.
- [USB Activity Shutdown Triggers](https://awesome-repositories.com/f/hardware-iot/usb-device-communication/usb-device-identification/usb-activity-shutdown-triggers.md) — Triggers immediate power-off sequences when unauthorized USB device changes are detected.
- [USB Device Whitelist Managers](https://awesome-repositories.com/f/hardware-iot/usb-device-communication/usb-device-identification/usb-device-whitelist-managers.md) — Manages a configuration of trusted hardware to prevent accidental shutdowns during legitimate usage.

### Operating Systems & Systems Programming

- [USB Device Connection Watchers](https://awesome-repositories.com/f/operating-systems-systems-programming/hardware-interfacing-drivers/peripheral-passthrough/usb-passthrough/usb-device-connection-watchers.md) — Implements event-driven monitoring to detect USB device connection and disconnection events in real time.
- [Anti-Forensic Data Protection](https://awesome-repositories.com/f/operating-systems-systems-programming/memory-protection-managers/memory-protection-engineering/anti-forensic-data-protection.md) — Prevents data recovery from volatile storage by wiping memory and swap space during emergency power-off.
- [Power Management](https://awesome-repositories.com/f/operating-systems-systems-programming/power-management.md) — Controls system power states to force a hard stop of the operating system upon security triggers.
- [Secure Data Erasure](https://awesome-repositories.com/f/operating-systems-systems-programming/secure-data-erasure.md) — Ensures data cannot be recovered from memory by forensic-level overwriting of RAM and swap space. ([source](https://github.com/hephaest0s/usbkill#readme))

### Development Tools & Productivity

- [Sequential Task Execution](https://awesome-repositories.com/f/development-tools-productivity/task-dependency-management/agent-task-dependency-resolvers/sequential-task-execution.md) — Executes a strict linear sequence of cleanup scripts and binaries before initiating system shutdown.
