2024-11-10 11:53:00 +01:00
# nc_password_client
2024-11-16 22:27:15 +01:00
Command line interface (CLI) for the Nextcloud Passwords app.
2024-11-12 07:47:22 +01:00
Manage your password and import them from [Password Store ](https://www.passwordstore.org/ ).
2024-11-10 11:53:00 +01:00
## Requirements
2024-11-12 07:47:22 +01:00
See requirements.txt
2024-11-16 22:27:15 +01:00
To cache the passwords locally the application uses the system keyring to store a random password that encrypts the cache file.
Tested in Ubuntu 24.10 with Gnome 47 and Nextcloud 30.0.2. But should work with similar setups. Create an [issue ](https://repos.susurrando.com/adelgado/nc_password_client/issues ) if you want me to test it in a different setup, but I can promise much.
2024-11-10 11:53:00 +01:00
## Installation
### Linux
2024-11-16 21:54:10 +01:00
To install for example in your ~/.local/bin folder:
```bash
./install.sh --destination ~/.local/bin
```
To install system-wide:
```bash
sudo ./install.sh --destination /usr/local/bin
2024-11-10 11:53:00 +01:00
```
2024-11-16 22:06:35 +01:00
Change your configuration file in "${HOME}/.config/nc_password_client.conf" (see the example in the config folder).
2024-11-10 11:53:00 +01:00
## Usage
2024-11-12 07:47:22 +01:00
Usage: nc_password_client.sh [OPTIONS] COMMAND [ARGS]...
2024-11-12 07:44:35 +01:00
2024-11-16 22:18:12 +01:00
### Options:
2024-11-22 13:56:20 +01:00
| option | parameters | description |
| ------------------------- | ------------------------------------------ | --------------------------------------------------------------- |
| -d, --debug-level | [CRITICAL|ERROR|WARNING|INFO|DEBUG|NOTSET] | Set the debug level for the standard output. |
| -f, --output-format | [json|yaml|plain] | Set the output format.|
| -l, --log-file | TEXT | File to store all debug messages. |
| -H, --host | TEXT | Nextcloud host name [required] |
| -u, --user | TEXT | Nextcloud user name [required] |
| -a, --api-token | TEXT | Nextcloud user's application token [required] |
| -p, --cse-password | TEXT | Nextcloud user's end-to-end encryption password |
| -t, --timeout | INTEGER | Timeout for HTTPS requests |
| -c, --cache-duration | INTEGER | Number of seconds to hold the list of passwords |
| -P, --https-proxy | TEXT | HTTPS proxy to use to connect to the Nextcloud instance|
| -F, --field-replacements | TEXT | Pairs of field names to be replaced separated by a : (colon). Like: -F login:username |
| --config | FILE | Read configuration from FILE. |
| --help | | Show this message and exit. |
2024-11-16 22:18:12 +01:00
### Commands:
2024-11-16 22:22:21 +01:00
| command | description |
| ------------------------ | ---------------------------------------------- |
| create-password |Create a password |
| create-passwords-folder |Create a password folder |
| delete-all-passwords |Delete all passwords |
| delete-password |Delete a password |
| delete-passwords-folder |Delete a password folder |
2024-11-22 13:56:20 +01:00
| import-csv | Import passwords stored in a CSV file to Nextcloud Passwords |
2024-11-16 22:22:21 +01:00
| list-passwords-folders |List all password folders |
| ls |List all password |
2024-11-16 22:18:12 +01:00
| migrate-pass |Migrate Password Store passwords to Nextcloud...|
2024-11-16 22:22:21 +01:00
| remove-duplicates |Remove duplicate passwords |
2024-11-22 13:56:20 +01:00
| search | Search for a password (or passwords) that... |
2024-11-16 22:22:21 +01:00
| show |Show a single password |
2024-11-16 22:18:12 +01:00
Use --help after the command to get more details of it's options