83 lines
1.8 KiB
Markdown
83 lines
1.8 KiB
Markdown
# whspbrd
|
|
|
|
Simple end-to-end encrypted terminal chat with a relay server.
|
|
|
|
## Build
|
|
|
|
```bash
|
|
go build -o whspbrd
|
|
```
|
|
|
|
## Server
|
|
|
|
```bash
|
|
./whspbrd --mode server --listen :9090
|
|
```
|
|
|
|
## Client
|
|
|
|
First run once to print your identity (share with others):
|
|
|
|
```bash
|
|
./whspbrd --mode client --show-identity
|
|
```
|
|
|
|
Then connect (you need the peer fingerprint and base64 public key):
|
|
|
|
```bash
|
|
./whspbrd --mode client --connect 127.0.0.1:9090 --peer <peer-fingerprint> --peer-key <base64-pubkey>
|
|
|
|
## TUI
|
|
|
|
```bash
|
|
./whspbrd --mode client --tui --connect 127.0.0.1:9090
|
|
```
|
|
|
|
TUI commands:
|
|
|
|
- `/add <name> <pubkey>` add a contact.
|
|
- `/rename <name|fingerprint> <new-name>` rename contact.
|
|
- `/remove <name|fingerprint>` remove contact.
|
|
- `/trust <pubkey>` trust a peer key.
|
|
- `/sendfile <path>` send a file.
|
|
- `/whoami` show your fingerprint.
|
|
- `/pubkey` show your public key.
|
|
- `/help` list commands.
|
|
|
|
TUI navigation:
|
|
|
|
- `Tab` switch focus between Users and Input.
|
|
- `Enter` send message.
|
|
- `Up/Down` select contact in Users.
|
|
- `PgUp/PgDn` scroll chat history.
|
|
- `Ctrl+U` / `Ctrl+D` page up/down.
|
|
- `Home` / `End` jump to top/bottom of chat.
|
|
|
|
## Self-test
|
|
|
|
```bash
|
|
./whspbrd --selftest
|
|
```
|
|
```
|
|
|
|
During chat, commands:
|
|
|
|
- `/whoami` shows your fingerprint.
|
|
- `/pubkey` shows your base64 public key.
|
|
- `/trust <base64-pubkey>` stores a peer key (TOFU).
|
|
- `/sendfile <path>` sends a file (images supported).
|
|
- `/quit` exits.
|
|
- `/list` shows last 50 messages (stored locally).
|
|
|
|
## Data locations
|
|
|
|
- Config: `$XDG_CONFIG_HOME/whspbrd` (fallback `~/.config/whspbrd`)
|
|
- Data: `$XDG_DATA_HOME/whspbrd` (fallback `~/.local/share/whspbrd`)
|
|
|
|
Files:
|
|
|
|
- `identity.key` long-term private key.
|
|
- `peers.json` trusted peers for TOFU.
|
|
- received files are written into the data directory.
|
|
- `messages.db` stores chat history (SQLite).
|