np_passwords v0.1.0 ​
Codes, logins and a keychain for every lock on the server. Doors, safes, stashes, laptops, computer logins, Wi-Fi and 2FA all ask through np_passwords. A resource registers a lock once and later only asks "did this player get in?". It never stores, sends or sees the secret. Players get a Passwords app in np_phone that remembers what their character knows.
It uses the Nimbus UI look of np_hud and np_phone: grey glass, glossy squircle tiles, and colour only where it means something (green unlocked, orange weak or locked out, red leaked). It runs on es_extended, qbx_core and qb-core, or standalone (np_character aware). Items and stash locks work best with np_inventory, with ox_inventory and qb-inventory as fallbacks. Requires oxmysql and np_prophandler 1.1.0+ (doors and keypad props). No ox_lib.

| Login with saved logins | Password |
|---|---|
![]() |
![]() |
| Phrase | Pattern |
![]() |
![]() |
| 2FA code | Create a code |
![]() |
![]() |
| Wrong code | Locked out |
![]() |
![]() |
| Unlocked | Save / update toasts |
![]() |
![]() |
| Cracking | Shoulder surfing |
![]() |
![]() |
| Warrant keychain read | Liquid Glass |
![]() |
![]() |

The screenshots come from the browser mock (see Development). The UI ships in English and German.
At a glance ​
- Locks live in np_passwords.
RegisterLockonce (or a static lock in the config), thenPrompt(id)returnstrueorfalse. Lock codes are stored only as bcrypt hashes (GetPasswordHash) and compared on the server. See Locks & doors. - Six prompt types: PIN keypad, password, login (user + password), word phrase, 3×3 pattern and 6-digit 2FA code. Wrong tries count per lock for everyone; after 3 (default) the keypad locks for 45 s and the owner is alerted. See Prompts & autofill.
- Keychain and autofill: what a character knows is stored encrypted per character. TAB fills a saved code, the login dropdown lists own and shared logins, and after a typed success a Save / Update toast (Y / N) follows. Autofill never sends the secret to the client.
- Proximity prompts at locks with coords: E unlock with a saved code (or lock an open door again), G enter a code, H watch someone type. Doors are optional per lock and synced to everyone through np_prophandler, with auto-relock.
- Create and rotate codes with a generator (PIN, password, phrase, pattern), rules from the caller and strength shown as time to crack. Owners change codes, hand out guest codes and see the history.
- Passwords app in np_phone: categories, nearby doors, hold-to-reveal, share to a nearby player, paper notes, 2FA codes, a security check (leaked, weak, reused) and shared vaults for gangs, jobs and custom groups. See Passwords app.
- 2FA:
RequireCode(src, app)asks for a rotating 6-digit code. The first time, it arrives by SMS; after that it fills from the Codes tab. See 2FA codes. - Crime & police: code breaker cracking minigame, shoulder surfing, paper notes, leak detection, and a warrant keychain read for officers. See Crime & police.
- Discord DMs (optional np_discord): players DM the bot
passwordsorpassword bankand get their saved codes as spoilers, also while offline. Off by default. See Discord DMs. - Stash locks for np_inventory stashes (
stash:<id>) and an opt-in np_gangs gang stash lock. - For other NUIs: drop-in web components
<np-password>,<np-password-new>and<np-otp>. The host page never gets the secret. See Web components. - Staff tools (optional np_admin): permission nodes instead of ACE, live settings,
/pwlockand staff actions.
Quick example ​
-- server: register a safe once (persisted, idempotent)
exports.np_passwords:RegisterLock({
id = 'apt12:safe', label = 'Bedroom safe', icon = 'vault', type = 'pin', length = 6,
owner = { type = 'char', id = cid }, coords = vector3(-1150.2, -1520.4, 10.6),
generate = true, -- random code, saved to the owner's keychain
})
-- client: ask for it (yields)
local ok, reason = exports.np_passwords:Prompt('apt12:safe')
if ok then TriggerServerEvent('apartments:openSafe', 'apt12') end
-- server: trust only what np_passwords saw
RegisterNetEvent('apartments:openSafe', function(apt)
if not exports.np_passwords:ConsumeUnlock(source, apt .. ':safe') then return end
exports.np_inventory:OpenInventory(source, 'stash', apt .. '_safe')
end)













