A secure CLI to manage secrets locally with encryption, master password, and clipboard support.
Project description
🔐 pacli - Secrets Management CLI
pacli is a secure, local-first secrets manager that stores your passwords, API keys, and SSH credentials with encryption and master password protection - no cloud dependencies required.
Features
- Securely store and manage secrets locally
- Master password protection
- Support separate options for token, password, and SSH connections
- Add, retrieve, update, and delete secrets
- Copy secrets directly to your clipboard
- SSH connection management with key file support
- URL shortening with LinklyHQ integration
- Export list of secrets into JSON or CSV file
- Easy-to-use command-line interface
- Web UI for managing secrets through a modern web interface
Installation
pip install pacli-tool
Usage
To see all available commands and options:
pacli --help
Common Commands
| Command | Description |
|---|---|
init |
Initialize pacli and set a master password |
add |
Add a secret with a label |
get |
Retrieve secrets by label |
get-by-id |
Retrieve a secret by its ID |
update |
Update old secret by label |
update-by-id |
Update old secret by its ID |
list |
List all saved secrets |
delete |
Delete a secret by label |
delete-by-id |
Delete a secret by its ID |
ssh |
Connect to SSH server using saved credentials |
short |
Shorten URLs using LinklyHQ service |
cc |
Copy stdin content to clipboard |
change-master-key |
Change the master password without losing data |
export |
Export secrets to JSON or CSV format |
web |
Launch the Web UI for managing secrets |
version |
Show the current version of pacli |
Examples
Adding and Retrieving Secrets
# Initialize pacli (run once)
pacli init
# Add a password
pacli add --pass github
# Add a token
pacli add --token api-key
# Add SSH connection
pacli add --ssh ec2-vm user:192.168.1.100
# Add SSH connection with key file
pacli add --ssh ec2-vm user:192.168.1.100 --key ~/.ssh/id_rsa
# Retrieve a secret
pacli get github
# Connect via SSH
pacli ssh ec2-vm
# Export secrets to JSON
pacli export --format json --output my_secrets.json
# Export secrets to CSV
pacli export --format csv --output my_secrets.csv
# Shorten a URL
pacli short https://example.com/very/long/url
# Shorten with custom name and copy to clipboard
pacli short https://example.com -n "My Link" --clip
# Copy file content to clipboard
cat file.txt | pacli cc
# Copy command output to clipboard
echo "Hello World" | pacli cc
# Copy API response to clipboard
curl -s https://api.example.com/data | pacli cc
Web UI
Launch the Web UI to manage your secrets through a modern, user-friendly interface:
# Start the Web UI (opens in your default browser)
pacli web
# Start on a custom host and port
pacli web --host 0.0.0.0 --port 8080
# Start without opening browser
pacli web --no-browser
The Web UI provides:
- 🔐 Master password authentication
- 📋 View, add, edit, and delete secrets
- 🔍 Search and filter secrets by type
- 📋 Display secrets with creation/update timestamps
- 👁️ Toggle secret visibility
- 📋 Copy secrets to clipboard
- 🎨 Responsive design for desktop and mobile
Display Format
- Credentials are shown as:
username:password - SSH connections are shown as:
user:iporuser:ip (Key: /path/to/key)
Copy to Clipboard
To copy a secret directly to your clipboard, use the --clip option:
pacli get google --clip
Pipeline Usage
Use pacli cc to copy any command output or file content to clipboard:
# Copy file contents
cat ~/.ssh/id_rsa.pub | pacli cc
# Copy command output
ls -la | pacli cc
# Copy JSON response
curl -s https://api.github.com/user | pacli cc
For more information, use pacli --help or see the documentation.
Tips
Avoid Master Password Prompts
To avoid entering your master password repeatedly, you can set it as an environment variable:
# For current session only
export PACLI_MASTER_PASSWORD="your-master-password"
# Or add to your shell profile for permanent use
echo 'export PACLI_MASTER_PASSWORD="your-master-password"' >> ~/.bashrc # For bash
echo 'export PACLI_MASTER_PASSWORD="your-master-password"' >> ~/.zshrc # For zsh
Security Note: Adding the password to your shell profile makes it persistent but less secure. Use the session-only approach for better security.
URL Shortening Setup
To use the URL shortening feature, set up your LinklyHQ credentials as environment variables:
# Set LinklyHQ credentials
export PACLI_LINKLYHQ_KEY="your_api_key"
export PACLI_LINKLYHQ_WID="your_workspace_id"
# Add to your shell profile for permanent use
echo 'export PACLI_LINKLYHQ_KEY="your_api_key"' >> ~/.bashrc
echo 'export PACLI_LINKLYHQ_WID="your_workspace_id"' >> ~/.bashrc
Visits here to get your credentials.
Demo
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 pacli_tool-1.3.1.tar.gz.
File metadata
- Download URL: pacli_tool-1.3.1.tar.gz
- Upload date:
- Size: 66.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4b2afed140fbcdf681ec56b7966851191220dff7fed28cdcd50d3efa780836d0
|
|
| MD5 |
c3daec5ef5754de1865ffa20f42d6754
|
|
| BLAKE2b-256 |
537083142f7f9edd337ecc8169afaf7962b1aac1d6d00d5ba1a69ccd03e744ee
|
Provenance
The following attestation bundles were made for pacli_tool-1.3.1.tar.gz:
Publisher:
pypi-publish.yml on imShakil/pacli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pacli_tool-1.3.1.tar.gz -
Subject digest:
4b2afed140fbcdf681ec56b7966851191220dff7fed28cdcd50d3efa780836d0 - Sigstore transparency entry: 760801130
- Sigstore integration time:
-
Permalink:
imShakil/pacli@a38bcc31fedda9f78e95a1e4148b57763df35e2b -
Branch / Tag:
refs/tags/v1.3.1 - Owner: https://github.com/imShakil
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@a38bcc31fedda9f78e95a1e4148b57763df35e2b -
Trigger Event:
push
-
Statement type:
File details
Details for the file pacli_tool-1.3.1-py3-none-any.whl.
File metadata
- Download URL: pacli_tool-1.3.1-py3-none-any.whl
- Upload date:
- Size: 36.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f160dcf2b74612e079f533883bf3f06c17ecd522b4310f65b611f4af62f784e5
|
|
| MD5 |
f8ae917479efca122f5959b16757b9c1
|
|
| BLAKE2b-256 |
897a9bbc19338fcc3d78d1abbbfa6b540e83ababd363db8fd5245d7a4539eccd
|
Provenance
The following attestation bundles were made for pacli_tool-1.3.1-py3-none-any.whl:
Publisher:
pypi-publish.yml on imShakil/pacli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pacli_tool-1.3.1-py3-none-any.whl -
Subject digest:
f160dcf2b74612e079f533883bf3f06c17ecd522b4310f65b611f4af62f784e5 - Sigstore transparency entry: 760801132
- Sigstore integration time:
-
Permalink:
imShakil/pacli@a38bcc31fedda9f78e95a1e4148b57763df35e2b -
Branch / Tag:
refs/tags/v1.3.1 - Owner: https://github.com/imShakil
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@a38bcc31fedda9f78e95a1e4148b57763df35e2b -
Trigger Event:
push
-
Statement type: