Secret CLI is a command-line tool designed for securely managing secrets and sensitive information. It provides a simple and efficient interface for creating, storing, and retrieving secrets in a secure manner.
- Secure Storage: Safely store your secrets using encryption.
- User Authentication: Register and authenticate users to access their secrets.
- Command-Line Interface: Simple and intuitive command-line interface for managing secrets.
- Cross-Platform Compatibility: Works on any system with a compatible terminal.
- Easy to Use: Minimal setup required for quick access to your secrets.
To install Secret CLI, follow these steps:
-
Download the Binary from here based on your machine architecture.
If you are not sure. Try these commands_ Ubuntu:
uname -m
x86_64
indicates an AMD/Intel architecture.armv7l
or aarch64 indicates an ARM architecture.
Mac:
uname -a
Windows:
echo %PROCESSOR_ARCHITECTURE%
-
Move the Binary to a Directory in PATH
sudo mv <file_name> /usr/local/bin/secretcli
-
Make the Binary Executable
chmod +x /usr/local/bin/secretcli
-
Verify the Installation and Set Master Password
secretcli
Note:
If you face any issue like permission error or not trusted, then follow this alternative way_
- Clone This Repo in Your PC.
- Install Golang:
version >= 1.23
cd
to the repo =>cd secretcli
- Build the Project =>
go build -o secretcli cmd/secretcli.go
- Make the Generated Binary Executable =>
chmod +x secretcli
- Move the Binary =>
sudo mv secretcli /usr/local/bin/
- Verify the Installation and Set Master Password
secretcli
-
List All Secrets
secretcli secret -list
-
Add a Secret
secretcli secret -add //Follow the prompt and insert values
-
Edit a Secret
secretcli secret -edit <id_number>
-
Delete a Secret
secretcli secret -del <id_number>
By default the user session expiry limit is set to 5 minutes
. But if any user want to update the expiry they can use the following commands_
-
Update Session Expiry Command
secretcli auth -set-expiry <expiry_time>
Here, the available options for expiry are:
s
-> secondsm
-> minutesh
-> hourso
-> no-expiry (never need to authenticate again)
-
To set a
10 minutes expiry
user can use the following command:secretcli auth -set-expiry 10m
-
To set
no expirty
user can use the following command:secretcli auth -set-expiry o
If you want to take a backup of the saved secret list, you can export them in a json file. To do so, use the following command_
secretcli secret -export
This is applicable for exporting the secrets only. User data cannot be exported.
Contributions are welcome! Please open an issue or submit a pull request to enhance the functionality of Secret CLI. Here are the reference links_
- Contributing Guidelines - Learn how to contribute to the project.
- Code of Conduct - Be sure to follow our code of conduct when participating in the project.
- License: This project is licensed under the MIT License. See the LICENSE file for more details.