Access control
Lock
Fast sign and server-side locks for doors, containers, redstone access, group permissions, and property-aware building.
01
What it handles
Sign locks
Private and additional-user signs support players, LuckPerms groups, everyone access, and automatic timers.
Complete protection
Blocks unauthorized use, breaking, explosions, pistons, redstone opening, and hopper transfer.
Paired structures
Double chests and paired doors are protected and operated as one logical lock.
Inherited groups
Transitive LuckPerms membership lets ranks inherit access from broader RP groups.
Builder auto-lock
Session-scoped auto-locking creates signless persistent locks while placing configured blocks.
Digital locks
Authorized staff can create and remove signless locks with property-scoped management rights.
Warrant access
Justice can register narrowly scoped warrant bypasses without giving officers permanent lock management.
Memory-backed checks
Interaction checks use an in-memory location index; SQLite is touched only when locks change.
02
Detailed guide
Lock is the MC Skylines Paper 1.21.11 / Java 21 locking module. Its interaction hot path is entirely memory-backed; SQLite is touched only when a lock changes. Locks protect all Bukkit inventory blocks—including chests, barrels, shulker boxes, hoppers, droppers, dispensers, furnaces, brewing stands, lecterns, crafters, and decorated pots—plus ender chests, doors, trapdoors, fence gates, double chests, and paired doors from unauthorized use, breaking, explosions, pistons, redstone opening, and hopper transfer.
Paired double doors are one logical lock. A sign may be attached directly to either door or to the solid block immediately above or below it. Clicking either door opens or closes both doors together, and configured timers close the pair together.
Sign locks
Normal-right-click a lockable block with a sign. Lock places and protects the sign immediately without opening the sign editor, while still sending a real BlockPlaceEvent through WorldGuard and other build protection. You can also place a sign normally on a door or its lintel/foundation block. The finished sign becomes:
[Private]
YourName
access entry
access entryAccess entries may be:
PlayerNameor[player:PlayerName][police]or[group:police][Everyone][Timer:1s],[Timer:2s],[Timer:3s], or longer durations such as[Timer:2m]
LuckPerms inheritance is transitive. If sergeant inherits police (even through intermediate groups), a sergeant can use a lock containing [police]. Membership results are cached and invalidated by LuckPerms recalculation events.
Normal-right-click with another sign on a lock you own to create a [More Users] sign without opening the editor. Sneak-placing a sign opts out completely: the editor opens, the text is preserved, and the sign is not attached to the lock. To change a lock, right-click its sign to select it and run /lock <line> <text>; use - as the text to clear a line. Breaking or otherwise removing the primary [Private] sign removes the lock; breaking or removing a [More Users] sign removes only its entries. Missing signs are also reconciled on use, covering external block-edit tools which bypass normal break events. Conversely, if a recorded [Private] sign still exists but its lock record has disappeared, trying the protected block reconstructs the lock and its recorded access signs from their physical text and audit history.
Signless builder locks
Run /autolock on, then place trapdoors. Each receives a persistent server-side lock without a sign. The lock owner and, by default, members/owners of the WorldGuard property at that block can use it and remove it with /unlock while looking at it. /autolock off ends the build session. Auto-lock mode intentionally resets when the player disconnects.
WorldGuard property access is optional and affects only signless locks. Configure it under property-access.
Administrators with lock.digital.lock can look at any eligible block and run /digitallock to lock it immediately without enabling auto-lock mode. Digital locks can be removed with /unlock by their creator or, by default, any owner/member of the containing WorldGuard property. Grant lock.digital.unlock.anywhere to staff who should be able to use /unlock on digital locks in every property without receiving the broader lock.bypass permission.
Commands
/autolock on|off|status/unlock/digitallock/lock <line> <text|->/removesign/locks info/locks reload/lock bypass [on|off|status](also/locks bypass)
/lock tab-completes editable lines, one-, two-, and three-second timers, online player names, and loaded LuckPerms groups. /removesign removes all signs belonging to the targeted lock when the caller owns the containing WorldGuard region; ordinary region members cannot use it.
Having lock.bypass does not silently bypass locks. An administrator must explicitly enable /lock bypass (or /locks bypass); the mode resets on disconnect. It permits opening and using protected blocks only—it never grants editing, breaking, management, or removal—so a bypass interaction cannot destroy the lock.
Justice / warrant API
Lock registers the canonical dev.serverplugins.lockette.api.LockApi service and a legacy LocketteApi alias with Bukkit's ServicesManager. Justice can register a LockBypassProvider and return true only when a player has a valid warrant for the supplied locked block. Providers receive a LockAction, so warrant access can be limited to USE without granting MANAGE rights. Registrations are removable and providers from disabled plugins are discarded automatically.
The database is plugins/Lock/locks.db by default and uses WAL mode, foreign keys, indexed sign lookups, and an in-memory block-location index. Chat, sign-editor, notification, command, and error text is configurable as MiniMessage in plugins/Lock/messages.yml. On the first upgrade, Lock safely copies legacy plugins/Lockette data and retains the old folder as a backup. Remove the old Lockette JAR before starting the server. /lockette remains an alias for /locks.
Day-to-day lock workflows
For a normal sign lock, right-click the target with a sign without sneaking. Lock places the protected sign and records the lock immediately. Add up to two access entries on the primary sign, then attach [More Users] signs for additional entries. Select an attached sign and use /lock <line> <text> to edit it; - clears the chosen line.
For repetitive trapdoor construction, enable /autolock on, place the trapdoors, and disable it afterward. These locks are server-side and signless. For a one-off signless administrative lock, target the eligible block and run /digitallock.
/unlock removes a signless lock when the player is its creator or, under the default property policy, an owner/member of the containing WorldGuard region. It does not remove a sign lock. /removesign is the region-owner cleanup path for attached sign locks and is intentionally unavailable to ordinary region members.
Access evaluation
The owner always has access. Explicit player entries match the named player. Group entries use transitive LuckPerms inheritance, so a higher rank inheriting the listed group is accepted. [Everyone] opens use access to everyone. Timer entries control automatic closing rather than granting another principal.
Signless property access is separate from sign access and is configurable. The Justice warrant provider can grant a specific USE action at a locked block without granting management, breaking, or removal.
What protection covers
Registered locks prevent unauthorized interaction and breaking, explosion removal, piston movement, redstone opening, and hopper transfer where applicable. Double chests and paired doors resolve as one logical target. Paired doors open and close together, and their timers close the pair together.
Removing the primary [Private] sign removes the complete sign lock. Removing a [More Users] sign removes only entries contributed by that sign. The reconciliation path repairs stale database/sign mismatches when external editing tools bypass ordinary events.
Bypass mode
Holding lock.bypass alone changes nothing. Staff must explicitly enable /lock bypass; the state resets on disconnect. Active bypass grants use/open behavior only. It does not permit editing access lists, breaking blocks, or deleting locks, and it should not be confused with lock.digital.unlock.anywhere.
Lock testing checklist
- Protect a chest, double chest, each door arrangement, trapdoor, gate, furnace, hopper, lectern, crafter, and decorated pot used by the server.
- Test owner, named player, inherited group, everyone, outsider, active bypass, and warrant access.
- Test
[Timer]on single and paired doors. - Attempt breaking, explosion, piston movement, redstone activation, and hopper transfer.
- Remove a secondary sign, then the primary sign, and verify their different effects.
- Test autolock logout reset and property-member removal of signless locks.
- Restart and use external block editing on staging to verify reconciliation does not grant unauthorized access.
03
Commands
| Command | Usage | Description | Permission |
|---|---|---|---|
/autolock | /autolock [on|off|status] | Toggle automatic server-side trapdoor locking while building. | Subcommand-based |
/unlock | /unlock | Remove a server-side lock from the block you are looking at. | Subcommand-based |
/digitallock | /digitallock | Administratively add a server-side lock to the block being looked at. | Subcommand-based |
/forceunlock | /forceunlock | Force-remove any digital lock and break all signs attached to it. | Subcommand-based |
/lock | /lock <line> <text|-> or /lock bypass [on|off|status] | Edit a selected lock sign line. | Subcommand-based |
/removesign | /removesign | Remove prior occupants' lock signs from a WorldGuard region you own. | Subcommand-based |
/locksAliases: lockette, lockadmin | /locks <info|reload|bypass [on|off|status]> | Inspect or administer MC Skylines Lock. | Subcommand-based |
04
Permissions
| Node | Default | Description / children |
|---|---|---|
lock.use | Create and use ordinary sign locks. | |
lock.autolock | Use server-side trapdoor auto-lock building mode. | |
lock.unlock | Remove server-side locks the player is allowed to manage. | |
lock.edit | Select and edit lock signs owned by the player. | |
lock.removesign | Clear lock signs from WorldGuard regions owned by the player. | |
lock.info | Inspect the lock being looked at. | |
lock.admin | Administer locks and explicitly enable interaction-only bypass mode.Includes lock.use, lock.autolock, lock.unlock, lock.edit, lock.removesign, lock.reload, lock.bypass, lock.info, lock.forceunlock, lock.digital.lock, lock.digital.unlock.anywhere | |
lock.reload | No additional description. | |
lock.bypass | Enable interaction-only bypass mode with /lock bypass. | |
lock.forceunlock | Force-remove any lock and its attached lock signs for debugging or recovery. | |
lock.digital.lock | Create a digital lock directly with /digitallock. | |
lock.digital.unlock.anywhere | Remove digital locks with /unlock regardless of property membership. |
Command and permission references reflect the current plugin.yml manifests in this workspace.