VeilMesh Whitepaper
Updated 20 November 2026
Abstract
VeilMesh is an end-to-end encrypted messenger for people and organisations that cannot depend on a single network. Messages, files and calls are encrypted on the devices with established protocols — the Double Ratchet for one-to-one chats and MLS (RFC 9420) for groups. They travel between nearby devices directly over Bluetooth and local Wi-Fi, and over the internet through relays that never hold the keys. Anyone can have a private relay, from one person or a family to a team or a whole company: either a dedicated machine that VeilMesh runs for them, or VeilMesh Box on their own hardware, which keeps working where the internet is poor or absent: on ships, offshore platforms and remote sites, or in the field.
This document describes the threat model, identity, transports, cryptography, metadata handling, on-device storage, the relay architecture and the release process. How VeilMesh protects your messages, calls and data, and what our servers can and cannot see, is also described on the Security page.
1. Threat Model
VeilMesh is designed to protect against:
- A relay operator — VeilMesh itself, a hosting provider, or anyone who gains control of a relay — reading messages, files or calls.
- A network observer reading content or tampering with it on the wire, the radio or the local network.
- Forged or altered packets injected into the local mesh.
- Identity linkage through phone numbers or e-mail addresses — none are required.
- Loss of a device’s stored data to someone without its passcode, including a duress code that wipes the app.
What VeilMesh cannot hide or prevent:
- Someone who controls the device itself, such as malware on the phone. VeilMesh narrows this: an app passcode bound to the secure chip, a duress code that wipes the app, locked chats with their own key, auto-lock, no screenshots or screen recording on Android while an app passcode is set, and locked chats closing as soon as screen recording starts on iPhone.
- Delivery data on the relay: which anonymous Veil IDs are online and which one a message is for. No names, phone numbers or message content (section 6).
- A future quantum computer and a compromised device together. One-to-one chats, groups and the phone-to-computer link use post-quantum key agreement, so traffic recorded today stays protected. But the later steps of the Double Ratchet use X25519 alone, so a one-to-one session’s recovery after a key compromise is not protected against a quantum computer (section 4).
- Radio presence: someone nearby with the right equipment can notice that a phone is running the mesh, but not read what it sends.
2. Identity
Each account has an Ed25519 account key, created on the account’s first device. The Veil ID is the SHA-256 hash of the account’s public key, written in Base58Check. No phone number, SIM card or e-mail address is used. Contacts are added by Veil ID, contact link or QR code.
Devices. The account key stays on one device, the primary. It signs the account’s device list: a numbered list of the account’s devices, with each device’s public keys and which one is the primary. Every install has its own Ed25519 device key and its own X25519 key for key agreement; they are made on the install and never leave it. Everything a device does in its own name, from mesh packets to relay logins, is signed with its device key, and other apps trust that key only while the newest device list they hold names it. Only the primary links and unlinks devices (each change is a new version of the list), exports the seed, issues bot certificates and deletes the account. A device can be unlinked without changing the Veil ID. On the public relay an account has at most two devices: the primary and one linked device, which can be a phone, a tablet or a computer. A computer that mirrors a phone (section 4) is not a device of the account and does not count.
Restoring from the seed. The seed backup holds the account key only, never a device key. It is encrypted with a password of at least 12 characters under a key derived with Argon2id. Restoring it makes the new install the only primary: it signs a device list that names only itself, and every older device of the account drops out. A group member that receives the new list adds the restored install back to the group, and the app asks the person to request re-adding from each group. Message history does not come with the seed; it moves only directly from one device to another over the local network.
Deleting the account. Delete Account on the primary removes the account from the relay: its queued messages, its files, its devices, keys and group memberships. It also erases the linked devices: the primary signs an erase notice with the account key, and each linked device checks that signature before it wipes itself. The public relay keeps the notice for up to 30 days, so that a device that is offline still receives it. After that it keeps only a keyed hash of the Veil ID and the last version of the device list: a record that the account existed, so that a later restore from the seed starts above every old list. Private relays keep no such record. Delete Account on a linked device removes only that device.
Signatures. Every Ed25519 signature in VeilMesh is verified strictly, which refuses weak keys and altered signatures, so one signature can never be valid for two different messages.
3. Transports
VeilMesh chooses the path by payload and connectivity:
- Bluetooth Low Energy mesh carries text messages, group messages, channel posts, delivery acknowledgements and key exchanges between iOS and Android devices without internet. Packets are flooded to nearby devices; the radio header names no recipient. While local Wi-Fi reaches the same nearby devices, Bluetooth steps aside.
- Files over Bluetooth. Two phones that share a Bluetooth link can also send files over a Bluetooth L2CAP channel, with the same signed and encrypted link as over Wi-Fi. It is a switch in the settings, “Files over Bluetooth”, off by default and needed on both phones; on Android it needs Android 10 or later. Text stays on the ordinary Bluetooth link.
- Local Wi-Fi — the shared local network, and Apple peer-to-peer Wi-Fi between Apple devices — carries files and payloads larger than about 1 KB, such as group welcome messages, call setup and history transfer.
- Relays over the internet carry everything else over TLS WebSockets: the public VeilMesh relay, a customer’s private relay, or a VeilMesh Box on a ship’s network.
- Calls use WebRTC: end-to-end encrypted media, routed directly between devices where possible and otherwise through a TURN server or, for group calls, a selective forwarding unit (SFU). On private relays and VeilMesh Box, HTTPS and TURN share TCP port 443 for restrictive networks.
- Ghost Mode is a switch for the whole app. While it is on, messages, files and calls travel only over the local mesh, with no cloud sync and no push; only small protocol messages (delivery receipts, device-list updates and key-maintenance messages) still use the public relay. Private-relay conversations wait until Ghost Mode is off.
A conversation on a private relay goes only through that relay. It is never sent over the local mesh or through the public relay.
A proxy of the user’s choice. Where a network blocks or slows VeilMesh, the app can reach a relay through a proxy. Anyone can run one on their own server and share it as a link. The proxy is set per relay. It passes the app’s TLS connection through unopened, routing by the server name the app asks for, and it routes only VeilMesh’s own names. The app checks the relay’s certificate through it as it does without a proxy. While a relay has a proxy, every connection to that relay goes through it, and if the proxy is down the app does not fall back to a direct connection. The proxy’s operator sees the user’s IP address, when they connect and how much they send; not the Veil ID, the contacts or any content.
Every mesh packet is signed with the sending device’s Ed25519 device key, which the account’s device list names, and carries a small proof-of-work that is checked before the signature, so floods of junk frames are dropped cheaply. Radio headers are obfuscated against casual sniffing; this does not hide them from an observer who runs the app.
The mesh limits hops, packet size and request rate, so that no device nearby can flood it.
4. Cryptography
One-to-one chats. Sessions start with PQXDH, a hybrid of X3DH over X25519 and ML-KEM-768 (FIPS 203), over the relay and over the local mesh alike, and continue with the Double Ratchet. A contact added only by QR code, with no relay reached since, starts classically because the post-quantum key does not fit in the code; the session becomes post-quantum when the phones next exchange keys. Messages are encrypted with XChaCha20-Poly1305 under a fresh random 24-byte nonce; key derivation uses HKDF-SHA256 for the root chain and HMAC-SHA256 for the message chains. A peer’s signed prekey and session key are bound to its Veil ID through a signed identity bundle carrying both public keys. The ratchet header is authenticated as associated data, and a message without it is refused. Post-quantum protection covers the start of a session: the later Diffie-Hellman steps of the ratchet use X25519 alone. These protocols are implemented in VeilMesh’s own Rust core from the published specifications; VeilMesh does not use Signal’s code or servers.
Groups. Group chats use MLS (RFC 9420) with the post-quantum ciphersuite MLS_128_MLKEM768X25519_AES128GCM_SHA256_Ed25519 from the IETF draft post-quantum ciphersuites for MLS, whose code point is still provisional. Its key encapsulation is X-Wing, a hybrid of X25519 and ML-KEM-768 (FIPS 203); signatures stay Ed25519. An MLS group cannot change its ciphersuite, so groups made under the earlier classical suite are re-created by their authors. Each member’s place in a group is bound to a device key its account’s device list names; when a member’s newer list drops a device, the other members remove that device from the groups they share. The group key moves to a new epoch whenever members join or leave, and each member also refreshes its own key material about once a week, so a key compromised in the past stops opening new messages. Cost grows logarithmically with group size. An app accepts an invitation to a group only from an account in its contacts.
Calls. Voice and video calls, one-to-one and in groups, including screen sharing, are end-to-end encrypted; group media keys are derived from the group’s MLS state, so the call server forwards media it cannot decrypt. Call setup — offers, answers and ICE candidates with their IP addresses — is encrypted end to end before any transport, and the apps refuse to send or accept it unencrypted. Calls are built on our own build of Google’s open-source WebRTC library, pinned to a reviewed version and compared with Google’s upstream before every release to take in security fixes; group calls go through our own forwarding server built on the open-source str0m library.
Bots. A bot is added to a group by the person who owns it. It is an ordinary MLS member with its own keys and a certificate signed by its owner, which also states whether the bot passes messages to an external AI service. A bot reads the group’s messages from the moment it joins, with no earlier history, and does not take part in one-to-one chats. A bot can also post what other systems send it through a webhook. The webhook is served by the bot itself on the owner’s machine; each group has its own secret, signed requests are checked, and the bot encrypts the text into the group, so the relay never sees it.
Files. Attachments are encrypted on the device with AES-256-GCM in STREAM mode (64 KiB authenticated chunks) under a fresh key per file, and every chunk is verified on decryption.
Computer. The desktop app for macOS, Windows and Linux is a full client. It can have an account of its own or join the user’s account as its linked device (section 2). The other mode is Mirror Phone: the phone stays the only holder of the account, and the computer keeps the mirrored data in memory only, wiped on disconnect, screen lock or sleep. The phone-to-computer link combines a Noise handshake over X25519 (XXpsk3 for pairing, IKpsk2 for reconnects) with ML-KEM-768 (FIPS 203); both secrets feed the session keys through HKDF-SHA256 — a hybrid post-quantum design.
Randomness and key hygiene. Keys and nonces come from the operating system’s cryptographic random generator. Identity keys, ratchet state and mirror session state are wiped from memory when released; logs never contain private keys, seeds or session tokens.
5. Group Names, Receipts and Typing
- Group names are never sent to the relay; members receive the name inside an encrypted message from the person who adds them.
- Read receipts are end-to-end encrypted; receipts on the local mesh carry a blinded message identifier and a short random delay.
- “Typing…” indicators are sealed between the apps.
6. Metadata
A relay cannot read content. To deliver messages it sees anonymous key fingerprints (Veil IDs) with no name, phone number or e-mail address behind them: which of them are online, when, which one a message is for, and the size of attachments. VeilMesh reduces even this:
- No phone numbers or e-mail addresses — an account is a key.
- Group names, read receipts and typing indicators are protected as described in section 5.
- The relay holds each account’s signed device list, which it needs to admit devices. Any signed-in app can fetch it. It shows how many devices the account has, their public keys, which one is the primary and when each was added.
- Notifications for messages carry no content and no sender or chat identifiers, only a blinded tag that the phone recognises. An incoming-call notification carries the caller’s public key so the phone can ring; the call and its setup stay encrypted.
- Locked chats send neither file names nor file types to the relay; their files and thumbnails are stored there under a neutral name. The size of a file is visible.
- Relays keep encrypted messages for a limited time: the public relay deletes them at the latest about a week after they arrive, and on a private relay the owner sets the time.
- Relay logs use salted pseudonyms instead of account identifiers.
Sender privacy. When both sides run current apps, one-to-one messages (reactions included) and delivery receipts reach the public relay without the sender’s Veil ID: they are uploaded outside the authenticated connection. Group messages, calls and private-relay conversations are still sent over the authenticated connection, so the relay sees the sender’s Veil ID for them. The relay always sees the recipient’s Veil ID.
The app stores device lists and keys only for its own account and for accounts it has a chat, contact, group or channel with; a stranger nearby cannot make it store theirs.
7. On-Device Storage
- The local database is encrypted with SQLCipher under a random 256-bit key generated on the device.
- Identity keys and the database key are kept in the iOS Keychain (this device only, available after first unlock, excluded from backups) or, on Android, in encrypted storage wrapped by an Android Keystore AES-256-GCM key. Apple’s Secure Enclave supports only P-256, so the Ed25519 and X25519 keys live in protected software storage rather than in the enclave.
- On a Mac the keys are in the Keychain and on Windows in Credential Manager. On Linux the deb and rpm packages use the desktop keyring; the Flatpak keeps them in an encrypted keyring inside its own sandbox, unlocked through the desktop’s Secret portal, with no access to the user’s other secrets.
- An optional passcode is checked with Argon2id and, where the device has one, bound to its secure chip (the Secure Enclave on Apple devices, StrongBox or the trusted execution environment on Android), so it cannot be guessed on a copy of the data. A separate duress code wipes the identity keys and local storage.
- Seed backups are encrypted under a key derived with Argon2id from a password of at least 12 characters.
- Locked chats add a further key on the device for their messages and media.
8. Relays
Public relay. Operated by VeilMesh for everyone. It authenticates devices, queues encrypted messages for offline devices and stores encrypted attachments. It is built to know as little as possible:
- It holds no end-to-end keys, so it cannot read messages, files or calls, and neither can anyone who takes control of it.
- An account is registered with its public key alone, with no phone number, e-mail address or name. A device logs in with its device key, and only while the account’s newest device list names it.
- For one-to-one messages it does not see the sender’s Veil ID, and group names never reach it (sections 5 and 6).
- Encrypted messages are deleted at the latest about a week after they arrive.
- When an account is deleted, it keeps only a keyed hash of the Veil ID and the last version of its device list (section 2).
- Its logs use salted pseudonyms instead of Veil IDs, and notifications to Apple and Google carry only a blinded tag.
- Its software is built reproducibly on a dedicated build machine (section 9).
Private relays. A person, a family, a team or a company can have its own relay (Get your own relay):
- It runs on a dedicated machine with its own network, database, call server and backup storage; nothing is shared with other customers, and the customer chooses the region.
- The administrator becomes owner with a one-time key shown only to them; membership is by invitation, and the admin panel opens only from addresses the owner allows.
- Vendor access is the customer’s to grant. After setup, VeilMesh can log in to the machine only through an access window the owner opens in the admin panel; every login and every refused attempt is shown to the customer.
- The relay reports only operational health to VeilMesh: its address, status, software version, service checks, disk use, backup age, and certificate and license expiry. It never reports members, chats or messages.
- Backups are encrypted with the customer’s key and stored in another region.
- When a contract ends, the customer has 14 days to move their data; then VeilMesh destroys the machine, and the encrypted backups expire within 14 days.
VeilMesh Box is the same relay with its call servers, packaged to run on the customer’s own hardware — on board a vessel, offshore or in a data centre — including without internet. It can use a public TLS certificate or a long-lived self-signed one whose key is pinned in the invite, and runs on an offline license file when there is no connectivity. VeilMesh has no access unless the customer grants it.
Joining a relay. An invite carries the relay’s address and the fingerprint of its key. Before joining, the app shows the relay’s signed rules — who can join, how long history is kept, how often the relay key is renewed — and the fingerprint to check with the administrator.
Several relays in one app. One app can belong to the public relay and to private relays at the same time. A conversation with a contact on a private relay is a separate thread of that relay, and groups can be created on a private relay; each relay sees only its own conversations.
Data at rest for private relays. The key that opens a private-relay conversation on the device is made of two parts: one kept on the device and one held by the relay for that member. The relay’s part is encrypted to a key kept in the device’s secure chip (the Secure Enclave on iPhone and Mac, StrongBox or the trusted execution environment on Android 12 and later) and usable only while the device is unlocked. Neither a copy of the device’s data without the relay, nor the relay without the device, can open these conversations.
Waking a phone for a private relay. A sleeping phone can only be woken through Apple or Google. A private relay never holds the phone’s push token: the app seals the token to the VeilMesh push service, and the relay passes on only the sealed copy and pays for each wake with an anonymous credential. The wake travels through an Oblivious HTTP relay, so the push service does not learn which relay sent it. VeilMesh currently operates that Oblivious HTTP relay as well. The public relay wakes iPhones for incoming calls the same way, through the push service with anonymous credentials; its message notifications go to Apple and Google with the blinded tags described in section 6.
One exception applies to iPhone calls. To ring a closed app, an incoming call has to arrive as a VoIP push, and an iPhone has a single VoIP token, which the public relay uses as well. VeilMesh runs both the push service and the public relay, so it could notice that a Veil ID receives call wakes the public relay did not send. That would show that this Veil ID also uses some private relay, though not which one, and only at the times of those calls. Message wakes are not affected: on a private relay they use tokens the public relay never sees.
9. Software Supply Chain
- Relay and call-server images are built reproducibly on a dedicated build machine.
- Release packages for private relays and VeilMesh Box are signed with an Ed25519 release key kept offline; each machine verifies the signature before installing and rolls back automatically if the new version does not pass its health check.
- License files are signed by a dedicated signing service.
- This website is signed: every page and asset is listed in a signed manifest that the browser checks (veil-guard, our open-source tool), so a tampered server cannot silently change what you read.
- All third-party libraries, of the apps, the core and the servers, are checked against the OSV and RustSec vulnerability databases before releases.
- Every version of the apps and the relay gets a security review before it ships: a code review, penetration testing of our servers and test environments, testing of the phone apps against the OWASP Mobile Application Security standard (MASVS), and testing of the relays, their APIs and admin panels against the OWASP ASVS.
10. Limitations and Roadmap
- Hiding the sender’s Veil ID from the relay for group messages and calls, on the public relay and on private relays. For one-to-one messages on the public relay the sender’s Veil ID is already hidden. Message content is end-to-end encrypted in every case.
- Post-quantum recovery after a compromise in one-to-one chats: a post-quantum step in the Double Ratchet. Sessions already start post-quantum, and group key updates already use the post-quantum suite.
- Older app versions — some protections are relaxed for messages from earlier versions; they become strict as those versions stop being supported.
11. Version History
- 20 November 2026. Only an account in your contacts can add you to a group; a stranger nearby cannot make the app store their device lists or keys; every Ed25519 signature is verified strictly; the mesh limits hops, size and rate against flooding; SQLCipher 4.20; Android release builds allow no unencrypted connections; the Linux app, whose Flatpak keeps its keys inside its own sandbox; bots can post from webhooks, encrypted on the owner’s machine. Also described: key storage on computers.
- 2.2 — November 2026. Updated for app versions 2.1 and 2.2. App version 2.1: the account key kept on the primary device only, with a signed device list and a device key per install, so that only the primary links, unlinks, exports the seed and deletes the account; post-quantum MLS groups; unused code removed from the apps and the relay. App version 2.2: a restore from the seed makes the restored install the only primary; Delete Account erases the linked devices too, and the relay keeps only a keyed record that the account existed; groups remove devices that an account’s list drops; files over Bluetooth, and Bluetooth stepping aside while Wi-Fi reaches the same devices; the Windows app 1.1.0 with private relays; the Linux app 1.1.0, with private relays, from signed apt, dnf and Flatpak repositories. Also described: a proxy of the user’s choice. Corrected: ratchet headers without associated data are refused.
- 2.1 — November 2026. Updated for app version 2.0: post-quantum one-to-one sessions, the sender’s Veil ID hidden from the public relay for one-to-one messages, linked devices, the passcode bound to the secure chip, Ghost Mode for the whole app, bots in groups, private-relay threads and groups with their data at rest, phone wakes for private relays, and the relay retention period.
- 2.0 — October 2026. Rewritten against the current source code: threat model, private relays, desktop as a full client, group-key refresh, call encryption, notification tags, supply chain. Superseded statements of earlier versions were removed.
- 1.x — 2026. Earlier versions.