Official CLI for LocknKey - Secure, Zero-Knowledge Secret Management with environment injection.
Project description
locknkeycmd: Secure, Zero-Knowledge Secret Management CLI
locknkeycmd is the official command-line interface for LocknKey, a secure, end-to-end encrypted secret management platform. This tool allows developers to securely inject secrets into their applications and scripts at runtime, without storing them in plain text files (specifically preventing .env sprawl).
Features
- End-to-End Encryption: Secrets are decrypted only in memory on your local machine.
- Zero-Knowledge Architecture: The server never sees your unencrypted secrets.
- TOTP-Based Security: Uses your Google Authenticator secret to derive encryption keys, adding a layer of security beyond just passwords.
- Environment injection: seamlessly inject secrets into
npm start,python main.py, or any other command. - Multi-Environment: Support for Development (
-d), Staging (-s), and Production (-p) environments.
Installation
Install via pip:
pip install locknkeycmd
Prerequisites
- A Lockbox/LocknKey Account: Sign up at https://lock-box-ashy.vercel.app.
- 2FA Enabled: You must enable Two-Factor Authentication (Google Authenticator) on the Web Dashboard. The CLI requires this to decrypt your vault securely.
Quick Start
1. Authenticate
Log in to your account. This will open a browser window to authenticate with Google.
locknkeycmd login
2. Initialize Session (Unlock Vault)
Decrypt your master encryption key using your 2FA code. This session remains active locally so you don't need to re-enter it for every command.
locknkeycmd init
Enter your 6-digit Google Authenticator code when prompted.
3. Run Commands with Secrets
Inject secrets directly into your application process.
Syntax:
locknkeycmd run <project-name-or-id> -- <your-command>
Examples:
Run a Node.js app with Development secrets (Default):
locknkeycmd run my-api -- npm start
Run a Python script with Production secrets:
locknkeycmd run my-api --prod -- python main.py
Print secrets to console (useful for debugging/verifying):
locknkeycmd run my-api
Other Commands
Show Account Info:
locknkeycmd --show
List Organizations:
locknkeycmd --show --org
List Projects:
locknkeycmd --show --proj
Logout:
locknkeycmd logout
Security
locknkeycmd uses a combination of modern cryptographic primitives:
- Argon2id for key derivation (hardening your TOTP secret into an encryption key).
- NaCl (TweetNaCl/PyNaCl) for high-speed authenticated encryption (using XSalsa20-Poly1305).
No private keys are ever sent to the server.
Troubleshooting
- "Session Locked": Run
locknkeycmd initagain. - "Invalid Authenticator Code": Ensure your system time is synced.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file locknkeycmd-0.2.0.tar.gz.
File metadata
- Download URL: locknkeycmd-0.2.0.tar.gz
- Upload date:
- Size: 13.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c5308fe8c869dd3f41172333080611f9f9a3cd44bba8aad9752522ea7f23e601
|
|
| MD5 |
a1fefa83a508395d87317d246cc2ab14
|
|
| BLAKE2b-256 |
03d79be87e1e223a99d9aa39d01666b18e0fd764fdbc5cddf0d0bb225cd4f4e9
|
File details
Details for the file locknkeycmd-0.2.0-py3-none-any.whl.
File metadata
- Download URL: locknkeycmd-0.2.0-py3-none-any.whl
- Upload date:
- Size: 13.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
59b4235e3200af2ae08d4771bbaec7831d668992a691b09b281b91b9bea11c71
|
|
| MD5 |
a53bb59a26b421793ac38b64bbd987cd
|
|
| BLAKE2b-256 |
e65a478ead392ad49c53a51010e6142bfa9746329522bd866f0c718d5c979d3b
|