A highly secure, zero-allocation (#![no_std]), asynchronous hardware password manager built for the ESP32-S3 microcontroller using the Embassy framework.
This project operates as a composite USB device, acting simultaneously as a USB HID Keyboard (to automatically inject passwords into your host PC) and a USB CDC-ACM Serial Interface (to manage internal data via a command-line tool).
- Zero Heap Allocation (
no_std): Maximum memory safety and deterministic behavior using static abstractions andheaplessdata structures. - True Hardware Randomness (TRNG): Passwords are generated directly on-chip leveraging the ESP32-S3's physical silicon thermal noise generator.
- On-Chip Encrypted Storage: Utilizes a highly reliable, wear-leveled, crash-safe
littlefs2file system mapped directly onto the microcontroller's flash. - Dynamic UI (TFT Display): A smooth physical user interface built with
embedded-graphicsandembedded-menu. Whileembedded-menuis heavily designed for static structures inno_stdenvironments, this project implements a custom architecture to safely enable fully dynamic menu rendering and runtime updates without requiring a global allocator. - Dual-Interface USB Stack: Implements a single-cable composite USB stack for effortless automation and management.
- Microcontroller: ESP32-S3 (with native USB OTG support)
- Display: ST7789 TFT Display (SPI-driven)
- Controls: 1x Physical Boot/User Button (GPIO0)
While the password manager functions as a completely standalone USB HID device for credential injection, managing the internal flash storage (saving, generating, or deleting passwords) requires serial communication.
To keep concerns separated, the automation tool is hosted in its own dedicated repository:
👉 Hardware Password Manager CLI
The CLI automatically handles OS-level serial frame synchronization, transmission timeouts, and ensures your commands are processed safely without choking the hardware's internal packet buffers.
Once you have the CLI tool, you can communicate with the device using the following command structure:
# Save a custom credential pair to flash
cargo run -- save <service_name> <password>
# Generate a cryptographically secure password via on-chip TRNG and save it
cargo run -- generate <service_name> [optional_length]
# Completely wipe a credential from the LittleFS system
cargo run -- delete <service_name>This project is licensed under the MIT License - see the LICENSE file for details.