V2V

module
v0.10.0-wip.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2026 License: AGPL-3.0

README

🚀 V2V — Verifiable Anonymous Chat

[!WARNING] Pre-1.0: active development, no backward-compat guarantee. Significant changes (wire protocol, storage formats, CLI, etc) can land at any time. Always update client and server together.

🇻🇳 Tiếng Việt · Technical Docs

Chat without accounts. The server never asks for email, phone numbers, or any real identifying information.

  • No signup — you join with a name like Name#a1b2 and start chatting right away. No data links that name to you.
  • Optional identifier — a tripcode badge (◆ ab12) generated from a passphrase lets others recognize you across sessions, as long as you keep using it.
  • Disposable identities — just stop using a name or passphrase and that identity is gone. Starting over leaves no link between the old and the new.
  • Transparent history — every message links into a single server-wide hash chain. If a message is edited or reordered, every client can detect the break.
  • Passwordless admin login — moderators use Ed25519 key files or WebAuthn passkeys. No personal identifying information required.

Why V2V Exists

Most chat platforms are built around accounts, profiles, and permanent identities. V2V explores a different model: the conversation itself matters more than who is speaking.

It fits situations where people don't need an account — joining with just a name — but the discussion still benefits from continuity: messages stay referenceable, and anyone can independently check that the history hasn't been altered.

That works for casual communities and for teams alike: any group that needs attributable, verifiable discussion without running account infrastructure.

Quick Start

1. Get a binary

Download from releases or build:

make client          # -> public/V2V-linux-amd64 (host only)
make client ALL=1    # -> cross matrix (6 platforms; android is built with the NDK in CI)
make dev             # -> bin/v2v, bin/v2v-server, bin/v2vctl + fresh webterm (dev build)
make help            # see all targets

2. Join as guest

./public/V2V-linux-amd64 -s wss://chat.example.com -u "YourName"
# via proxy: --proxy socks5://127.0.0.1:1080 (http/https/socks5/socks5h;
# precedence --ask-proxy > --proxy > V2V_PROXY env > system proxy, or --ask-proxy for an interactive prompt)

3. Join with a tripcode

./public/V2V-linux-amd64 -s wss://chat.example.com -u "YourName" -t
# prompts for the secret tripcode (hidden input with a live strength
# meter, never passed as an argument); weak secrets ask to confirm
# (default No); offers to save it encrypted in tripcode.json afterwards.
# you will appear as: YourName#ab12
#                      └─ ✍️ ◆ ab12cd34  (colored, clickable to verify)

V2V_TRIPCODE env also works (CI only — prefer the encrypted file).

Type /help inside the chat for commands (/quit, /clear, /clearhistory, /whoami, /status, /showjoin, /autoverify, /tab, /meta, /find, /reply, /info, /expand, /copy).

Your message first appears grey with ⏳ and is replaced by the confirmed line once the server echoes it back. Unknown /commands are rejected locally and never broadcast (to send text starting with /, wrap it in a ``` code block).

Chat and system messages live on separate tabs: /tab switches between Tab 1 (chat) and Tab 2 (local & system). The bar shows [1:chat] 2:system with the active tab in brackets.

Keys and settings live in your OS config dir (~/.config/V2V/ on Linux, %AppData%\V2V on Windows, ~/Library/Application Support/V2V on macOS): key.json for identities, read-only config.jsonc for settings (JSONC comments allowed, copy template/client/config.jsonc to customize, v2v --encrypt-config to seal it). Override with -c/--config-dir (V2V_CONFIG_DIR) and -C/--cache-dir (V2V_CACHE_DIR). Extra flags: -v version, -a user-agent, -i server info, -j show join/leave (live display and catch-up history; replays filter joins by default).

For Admins

Create identities with v2vctl (build with make v2vctl / make v2vctl ALL=1 for all platforms):

# 1) Create the role (permissions live here, not in keygen)
./public/V2Vctl-linux-amd64 role create admin --unlimited --prefix "[Admin] "

# 2) Ed25519 key (classic, works everywhere)
./public/V2Vctl-linux-amd64 keygen ed25519 --role admin
# paste the printed snippet via: role add-identity admin --paste

# Login with a key file (-K path, or -k for the default key in the config dir)
./public/V2V-linux-amd64 -s wss://chat.example.com -u "Admin" -K key.json

Key files can be encrypted (v2vctl will ask for a passphrase, or use V2V_PASSPHRASE). Secrets travel as []byte and are wiped from RAM after use.

Web passkey enrollment (one-time link, 10 min):

./public/V2Vctl-linux-amd64 enroll --role member --label bob-laptop
# → https://chat.example.com/web/#enroll=...

See template/server/instances/default/config/roles.json and template/server/instances/default/.env for server configuration. Management commands default to the instances/default root; pass --root instances/<name> (or set V2V_ROOT) to target another instance.

Running the Server

Prebuilt server bundles and the multi-arch container image are published with each release; INSTALL.md is the full deployment guide.

From a release (recommended): download V2V-server-<os>-<arch> for your platform, extract it, then bootstrap and run:

./v2vctl config sync --dir . --to instances/default   # bootstrap from the bundled template
# edit instances/default/.env: PORT, ALLOWED_ORIGINS, ...
V2V_ROOT=instances/default ./server
# or via container: see INSTALL.md for the GHCR image flow

From source:

make v2vctl                    # -> public/V2Vctl-<os>-<arch>
./public/V2Vctl-$(go env GOOS)-$(go env GOARCH) config sync --dir . --to instances/default   # bootstrap the default instance from template
# edit instances/default/.env: PORT, ALLOWED_ORIGINS, ...
make server web                # -> public/server.bin + webterm/app.wasm
V2V_ROOT=instances/default ./public/server.bin
# or: docker compose up -d --build   (persists instances/default/data)
# extra instance: config sync --dir . --to instances/prod, then ENV_ROOT=instances/prod docker compose -p v2v-prod up -d --build
# or manage it: v2vctl instance init prod --port 10001 && v2vctl instance up prod

Open http://localhost:10000/web/ for the browser client.

Learn More

  • How it works: docs/TECHNICAL.md — architecture, wire protocol, tripcode crypto, storage, and security model.
  • Configuration: template/server/instances/default/.env has all env vars with comments (PORT, MAX_MESSAGE_LENGTH, HISTORY_FILE_PATH, WEBAUTHN_*, etc.).
  • Management tool: v2vctl --help (role create/list/show/update/delete/add-identity/import, keygen ed25519, enroll, migrate --preset native|wasm|custom, list, config sync/diff/check/manifest, instance init/list/status/up/down/restart/logs).

Issues and PRs are welcome.

Directories

Path Synopsis
cmd
v2vctl command
internal
chain
Package chain implements the global message log as a hash chain ("blockchain-lite"): every chat message links to the previous one, so altering any byte of any message (content, author, timestamp or ID) breaks the link and every link after it.
Package chain implements the global message log as a hash chain ("blockchain-lite"): every chat message links to the previous one, so altering any byte of any message (content, author, timestamp or ID) breaks the link and every link after it.
codebg
Package codebg renders markdown-style code spans in chat text with a distinct terminal background, mirroring how markdown shows inline code and fenced blocks.
Package codebg renders markdown-style code spans in chat text with a distinct terminal background, mirroring how markdown shows inline code and fenced blocks.
env
Package env is the single registry of environment variables the repo reads.
Package env is the single registry of environment variables the repo reads.
identity
Package identity holds the locally stored login identities shared by the chat client and the v2vctl management tool: a classic ed25519 key-file slot inside one versioned container.
Package identity holds the locally stored login identities shared by the chat client and the v2vctl management tool: a classic ed25519 key-file slot inside one versioned container.
linkify
Package linkify wraps plain http(s) URLs in chat text with OSC 8 hyperlink escapes plus SGR styling, so terminals and xterm.js render a clickable, underlined, bright-blue link.
Package linkify wraps plain http(s) URLs in chat text with OSC 8 hyperlink escapes plus SGR styling, so terminals and xterm.js render a clickable, underlined, bright-blue link.
markup
Package markup renders forum-style inline markdown (bold, italic, strikethrough), text(url) links and > quotes into terminal SGR sequences.
Package markup renders forum-style inline markdown (bold, italic, strikethrough), text(url) links and > quotes into terminal SGR sequences.
passprompt
Package passprompt is the single shared secret-entry component for the repo: hidden password input with optional live strength meter, double-entry confirmation, and default-No confirmation.
Package passprompt is the single shared secret-entry component for the repo: hidden password input with optional live strength meter, double-entry confirmation, and default-No confirmation.
strength
Package strength owns the passphrase-strength policy for the repo: zxcvbn scoring reported as a plain Report.
Package strength owns the passphrase-strength policy for the repo: zxcvbn scoring reported as a plain Report.
strutil
Package strutil holds one-line string helpers shared by the server and admin binaries (both are package main, so they cannot share unexported code).
Package strutil holds one-line string helpers shared by the server and admin binaries (both are package main, so they cannot share unexported code).
trustedproxy
Package trustedproxy resolves the real client IP behind an explicit, operator-configured chain of reverse proxies.
Package trustedproxy resolves the real client IP behind an explicit, operator-configured chain of reverse proxies.
tui
Package tui is the general terminal UI kit: confirmations and selections.
Package tui is the general terminal UI kit: confirmations and selections.
wire
Package wire is the single source of the chat protocol schema: the structs below define every message the client and server exchange.
Package wire is the single source of the chat protocol schema: the structs below define every message the client and server exchange.
blog
Package blog renders the server announcement pages.
Package blog renders the server announcement pages.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL