ChestPass
Lock chests and barrels behind a keypad PIN.
Paper
Highlights
- A clickable keypad built from inventory menus.
- PINs are hashed with SHA-256 and stored in the block's own persistent data, with no database.
- Unlocks last for a session, with an injectable clock so the timing logic is unit-tested.
- Locked containers cannot be broken; admins can bypass.
What it does
ChestPass lets players lock a chest, trapped chest or barrel behind a PIN. Opening a locked container shows a keypad built from an inventory menu; enter the right code and it stays unlocked for your session.
Design notes
- PINs are hashed with SHA-256 before storage and never kept in plain text.
- The lock lives in the block's own persistent data, so there is no database to manage and locks move with the world.
- Session timing goes through an injectable clock, which makes the expiry logic easy to unit-test.
- A protection listener stops locked containers from being broken. Admins with
chestpass.admincan bypass.
Platforms
| Platform | Minecraft | Version | Source |
|---|---|---|---|
| Paper | 26.1.2 | 1.1.0 | Source not public |
Built with
- Java
- Paper
- Gradle