# 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-key ## TUI ```bash ./whspbrd --mode client --tui --connect 127.0.0.1:9090 ``` TUI commands: - `/add ` add a contact. - `/rename ` rename contact. - `/remove ` remove contact. - `/trust ` trust a peer key. - `/sendfile ` 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 ` stores a peer key (TOFU). - `/sendfile ` 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).