A personal password/token manager TUI for developers to generate various types of hash/salted secrets and store them in different cloud based vaults
Because managing tokens, pins used in various dummy/dev apps require them to be generated first, and store them somewhere, I personally used 3 sites to generate random API dummy tokens, store them in other site. It become a big mess, and I thought there has to be a simple way where I can generate passwords and Do It mYself hence PassDIY.
- Generation of strong secrets like pins, passwords, API tokens, passphrases
- Generate X multiple secrets at once and pick X and X password generation algorithms
- Hash tokens/passwords with Argon2Id and Bcrypt
- Salt tokens/passwords
- Copy passwords to clipboard
- Hashicorp Vault integration to connect to secure vault and store generated secrets on cloud
- 1Password integration to connect to secure vault and store generated secrets on cloud
- hcpvaultconnect automatically connect to hcp vault via service principle
- hcpvaultstore store secrets into the vault via name=value format
- hcpvaultlist list log details about token created at, created by details
- 1passstore store secrets into the vault via name|password|url format
- 1passwordlist list secret names for connected vault
To allow PassDIY to store and connect to your Hashicorp vault you must create a service principle with Vault Secrets App Manager
permission. Also would need set below envs
export HCP_CLIENT_ID=<your-hcp-client-id>
export HCP_CLIENT_SECRET=<your-hcp-client-secret>
more detailed in ./Setup.md
To allow PassDIY to connect to your 1Password Vault you would need to set service principle anf the service account token
export OP_SERVICE_ACCOUNT_TOKEN=<your-service-account-token>
you can config PassDIY's password/token/pin char lengths additional confiurations in config/config.go
by changing below values
const (
PIN_DIGIT_LENGTH int = 6 // number of ints in pin digit
API_TOKEN_CHAR_LENGTH int = 60 // number of chars in a API token
PASWORD_CHAR_LENGTH int = 40 // number of chars in a password
PASSPHRASE_COUNT_NUM int = 5 // number of words in passphrase
MULTIPLE_VALUE_COUNT int = 5 // how many password/tokens you want to output
LOTTERY_WHEEL_COUNT int = 100 // how many times you want to generate token/password/pins to randomly pick one (pass100, pass10000)
SALT_EXTRA_LENGTH int = 10 // how many extra chars you want to add to a password/token
)
If you have make
installed, follow these steps to build, run, and install passdiy:
-
Build the project:
make build
-
Run the application:
make run
-
Install globally (optional):
sudo make install
You can then run it from anywhere with: passdiy
If you do not have make
you can build and run it traditionally with:
go run .
You can uninstall passdiy with:
sudo make uninstall
- dynamically change config
- add more vaults possibly vercel/Azure key vault
- add more hashing algos