Blog Make your @name

Blog · Security

The technical specs, and what we leave out

What protects your connection, your sign-in, your loops and your messages, from your phone to our database, as IRL runs on 23 November. Most of it anyone can check from outside. The rest is how we keep what you send. At the end: the parts we leave out on purpose, and why.

From your phone to our database

Every step is encrypted. Here is each one, and what protects it.

Held to HTTPS, and to the right certificates

Signing in

What your browser is told

Your loops and pictures

They’re kept in private storage: nobody can list it or read from it directly. A loop plays through a signed link that ends after ten minutes, made only for someone allowed to see it. An upload goes through a link signed for that one file, at its exact size.

Your messages

A key’s life

New this week. Each time the cipher seals a message, it uses a random 96-bit number called a nonce. If one ever came up twice under the same key, that key would be weakened. The chance grows with every seal, so now every seal is counted against its key, before what it sealed is stored. The count can run a little over, never under.

At 228 seals, about 268 million, our health check asks for a new key, and a person puts it in. That is sixteen times under the usual limit of 232, and the chance of any repeat by then is about one in two trillion. The limit itself is enforced: a key that reaches 232 seals nothing more, and text messages pause until the new key is in.

When the key changes, every deploy seals stored messages again with the new one. That includes the copies kept in our review record when a message is reported or held, and older copies kept before sealing, which are now sealed too. Each one is rewritten only if it hasn’t changed since it was read, so a re-seal can run beside the live site, or stop halfway and start again, without losing a message. An old key leaves the live site only once nothing stored is sealed with it, and our health check turns red if a stored message’s key is ever missing.

Backups hold what was stored when they were made, until they expire. So an old key is kept offline, out of the site, for as long as a backup might need it.

Checked against our real database

IRL Formal 5 writes two rules exactly: someone outside a conversation never reads its messages, and with no key, no message’s words are stored. Then it tests them against our real database code:

All pass. These are tests: they sample, they don’t prove. So a model checker also tries every order of every step in a key’s life, within a small size: sending and unsending, changing and retiring keys, and a deploy’s re-seal stopping anywhere and starting again. Across all 693,189 states it reaches, every rule holds. Switch off any one protection in the model and it finds the rule that protection is there for, broken.

It found one more problem, now fixed. When the key changed, a deploy moved stored messages to the new key while the version still serving didn’t have it yet. For a short time those messages couldn’t be opened, and for longer if the deploy then failed. Now they move only once the live version has sealed a message with the new key.

What IRL Formal is, and what it doesn’t claim, is in Checking the rules a bot must never get around.

What we watch

Our own health check reads the live site: whether the database connection is encrypted with a checked certificate, whether HTTP/3 is on offer, how many seals each key has made, and whether any key is missing. It turns red when one slips.

What this doesn’t cover

What’s next

What we leave out

This post covers what anyone can see from outside, like headers, DNS and how a connection is made, and how we keep what you send. Some of how we keep bots out is public too, in IRL Formal. What we don’t publish: the thresholds, the signals we look for, the details of how reviews decide, and which provider does what. Those work better unknown.

If you find a weakness, write to [email protected] and tell us how to see it. Please don’t test it on other people’s accounts; make your own.

New to IRL? Make your @name.