KaleidoTalk is an open-source, end-to-end encrypted instant messaging system built from scratch with privacy as its foundational principle. It combines Ed25519 identity keys, X25519 key exchange, AES-256-GCM symmetric encryption and HKDF-SHA256 key derivation so that only the participants of a conversation can read its content.
But encryption alone is not enough. Even when ciphertext cannot be read, packet sizes and timing still leak behaviour. KaleidoTalk therefore ships a cover traffic layer — a fixed-length packet protocol with random padding and randomised heartbeat intervals — that resists traffic analysis based on observable packet characteristics.
Version 3.0 adds automatic 24-hour key rotation for bounded forward secrecy, an irreversible account freeze backed by Ed25519 recovery certificates, and a modern bubble-chat interface — all under a trust-on-first-use model that removes reliance on centralised certificate authorities.
Every layer of the stack — identity, key exchange, transport, session, and network behaviour — is hardened independently, so a failure at any single layer does not expose your conversations.
Messages are sealed with AES-256-GCM before they leave the device. The server relays only ciphertext and never possesses a decryption key.
Each message uses a one-time ephemeral X25519 key pair that is discarded immediately after encryption — past messages stay sealed even if long-term keys are later compromised.
X25519 keys rotate every 24 hours; the server retains multiple key versions so delivery continues during the transition. A leaked key exposes at most a 24-hour window.
An Ed25519 recovery certificate is generated at registration. If credentials are stolen, the account can be permanently frozen — no server command or admin can unfreeze it.
All traffic is wrapped in fixed 2048-byte packets with random padding; randomised heartbeats mask idle periods. Packet size and timing reveal nothing about the conversation.
No certificate authorities. Server and contact identities are verified out-of-band via six human-readable BIP39 words — trust is your choice, not a corporation's.
Messages to offline contacts are queued on the server and delivered automatically on next login — before any other communication.
HMAC-authenticated requests with per-session sequence numbers and timestamp caching block replay; per-IP rate limiting with automatic banning mitigates flooding.
KaleidoTalk uses well-audited, industry-standard algorithms — never homebrew crypto — composed into a single coherent protocol.
| Component | Algorithm | Purpose |
|---|---|---|
| Identity key | Ed25519 | Signs sender identity; sender authentication & non-repudiation |
| Key-exchange key | X25519 (ECDH) | Shared-secret agreement, rotated every 24 h |
| Symmetric cipher | AES-256-GCM | Message encryption with built-in authentication |
| Key derivation | HKDF-SHA256 | Derives AES key & nonce from the ECDH secret |
| Password storage | PBKDF2-SHA256 · 600k | Server-side hash; brute-force resistant |
| Transport | TLS 1.2+ · RSA 2048 | Client–server channel; self-signed + TOFU trust |
| Fingerprints | BIP39 · 6 words | Human-verifiable identity comparison (66 bits) |
Defence in depth: passwords are additionally sealed with the server's X25519 public key before they ever reach the wire — so credentials stay confidential even if the TLS tunnel were terminated. The ephemeral key guarantees perfect forward secrecy: the private key is discarded the moment encryption completes.
Encrypting content hides what you say. Cover traffic hides whether you are saying anything at all — and how much.
Every packet is byte-for-byte the same length — a one-line message and a long attachment produce identical packets on the wire. Padding is drawn from a cryptographically secure RNG, so an entropy analysis cannot tell padding from data.
Real messages are fragmented and reassembled transparently; large payloads achieve 99.66% efficiency.
Both client and server emit padding-only packets at randomised intervals — a technique called traffic morphing. Idle standby looks identical to active conversation.
Pure padding packets carry no data — but on the wire, nobody can tell them apart from the real thing.
KaleidoTalk is accompanied by a technical whitepaper covering the architecture, protocol, threat model, security properties, and performance characteristics.
Complete protocol specification: key hierarchy, message encryption, session & HMAC authentication, replay and DoS protection, the irreversible freeze protocol, network command set, and security analysis.
| Feature | Signal | Tox | Matrix | KaleidoTalk |
|---|---|---|---|---|
| End-to-end encryption | ✓ | ✓ | Optional | ✓ |
| Forward secrecy | ✓ ratchet | ✓ ratchet | Partial | ✓ bounded (24 h) |
| Automatic key rotation | ✓ | — | — | ✓ 24 h cycle |
| Cover traffic | — | — | — | ✓ |
| Open source | ✓ | ✓ | ✓ | ✓ GPL-3.0 |
| No CA dependency | — | ✓ | — | ✓ TOFU |
| Irreversible account freeze | — | — | — | ✓ |
| Offline messages | ✓ | — | ✓ | ✓ |
| BIP39 fingerprints | Partial | Partial | — | ✓ 6 words |
KaleidoTalk's distinguishing contributions — cover traffic for metadata protection and an irreversible account freeze — are absent from mainstream alternatives.
An honest threat model matters as much as a strong one. KaleidoTalk is designed against a network-level adversary and a semi-honest (honest-but-curious) server.
KaleidoTalk is a self-hosted system: you control the infrastructure, your friends control their keys. Python 3.8+ is all you need.
# optional: use a virtual environment pip install -r requirements.txt
python run_server.py # first run: set an admin password · TLS certs generated in server_keys/ # configuration: edit config.json (host, port, rate limits, …)
python run_client.py # verify the server's 6 BIP39 words on first connection # register, keep your recovery key safe, and start chatting
On first connection, confirm the server fingerprint — 6 BIP39 words — through an independent channel. Compare contact fingerprints the same way.
Server-hosted (encrypted, cross-device login) or local-only keys — and generate your recovery certificate for the freeze mechanism.
Lost credentials? Permanently lock the account with the standalone tool — freeze_account.py — no server admin can reverse it.