KryptDisk 1.44: An Experimentation in Peer-to-Peer Proof-of-Work Time-Locked Encryption

κρῠπτός • (krŭptós) concealed, hidden, secret
Δίσκος • (dískos) quoit, disc, discus


Most reasonable people would grant that privacy is a function of liberty.
— Edward Snowden

Picture the scenario: you have something vital to share, but you require near perfect assurance that firstly this information will not be compromised in transmission and secondly it will remain confidential until a precise time of your choosing.

You distrust the internet as a medium, knowing the depth of government surveillance augmented by cutting-edge AI ... so you go retro, old school, lo tech. How low do you limbo? Floppy disk low if that's what it takes to duck the radar. It doesn't matter the format so long as it is physically solid and passed from hand to hand—air-gapped—between terminals.

You have to place your trust in something. Other than your dog maybe, probably not any single person absolutely, or human fidelity in general, certainly not a commercial platform's security promises nor any government privacy laws.

What then? Well, there are less malleable laws. The mathematical rules that govern encryption, for example, are consistent and apply universally. The same principles that make Bitcoin viable as a medium of exchange across a distributed global network are about as trustworthy as it's ever likely to get. And that's what KryptDisk 1.44 seeks to exploit.


Alice & Bob

Robert has something truly significant for Alice's eyes only: a secret formula, evidence of a corporate cover-up or covert government assassination program, or something as sentimental as a billet-doux.

For the aforementioned reasons he demurs from the orthodox channel of communication, favouring instead the courier. Better still, the method that defined Cold War intrigue—the classic dead-drop. Historically, park benches, lampposts, public lavatories, beneath bridges and within the hollows of trees were choice locations and the regular focus of tension in every espionage thriller. A trope that depicted a very real threat to the wellbeing of human assets.

So for peace of mind, Robert insists his payload be couriered to Alice (air-gapped), where even then it is only feasibly disclosed at an appointed time. And as such he opts for the cuckoo protocol inspired by the cuckoo clock, the greatest of 'Swiss' inventions, according to the fictional spy Harry Limes.

The Cuckoo Protocol

The cuckoo protocol depends upon the beating heart of the KryptDisk network. And as the name suggests, its function is to make something available only at a given time. In this instance, rather than a 'delightful' wooden cuckoo emerging from the recesses of a clock, a one-time key for the symmetrically encrypted air-gapped payload meant for Alice lands in her folder. This key is deployed to decrypt the payload she now has hopefully retrieved and uploaded by hand.

First though, the key is fragmented into separate chunks and released piecemeal in intervals according to a predetermined schedule of Robert's choosing: the final chunk could be set to land in Alice's folder 8 hours hence, 24 hours, 72 hours, 1 week , 1 month ... etc. When all the chunks have been released to Alice, she can reassemble her key and decrypt Robert's payload.

If the payload is intercepted, it is as indecipherable as any payload using the well-established XSalsa20-Poly1305 symmetric method of encryption. The key chunks are asymmetrically protected using X25519 elliptic-curve cryptography, allowing Robert to bind them to Alice’s cryptographic identity so that only she can recover them.

The network only relays the key fragments. It cannot read them—nor determine which node will ultimately receive them, reassemble the key and use it to decrypt any air-gapped payload. The network also accommodates secure messaging between nodes and very modest file transfers—also delivered in encrypted chunks and reassembled, but without time-locking and the ultimate protection of air-gapping.


The Beating Heart

KryptDisk is a living network, pulsing like an organism. It propagates payloads continually whether they are meaningful or not according to a stochastic process similar to Brownian motion that perpetuates traffic and keeps the mesh ticking over, or churning.

When a payload is generated, meaningful or otherwise, it is fired to a random node who relays it to another random node and so on until the whole network has relayed it at least once, before it decays.

Inevitably, any single payload collides with the same node more than once. But no node relays the same payload more than once. However, the collisions still count; and if a node meets the current network threshold of N counts, that node releases a fresh payload, meaningful or otherwise. Meaningful being an encrypted human generated payload as opposed to an automated dummy payload. For the sake of uniformity, there is ostensibly no discernible difference between the two classes. Same size, same characteristics and so on.

The collision rate per second is monitored in real time and logged with a view to establishing a measurable mean rate from across the network as the sample grows. This metric if constant enough is potentially an independently trusted source of timekeeping suitable for the cuckoo protocol.

In the meantime KryptDisk has outsourced timekeeping to an established proof-of-work (PoW) network and distant cousin of Bitcoin, but with a shorter block time—Dingocoin. A block time is the time taken for current network PoW to legitimise the latest cluster of transactions. The block is added to the chain and the overall block-height increases by one. The blockchain is the network's established ledger of every legitimate transaction.

Why Dingocoin (or any suitable Bitcoin variant) and not KryptDisk's own PoW in support of the cuckoo protocol?

Why add to the global energy consumption when we can exploit existing infrastructure that already does the heavy work. KryptDisk does actually deploy a modest SHA-256 PoW gate to protect the network from cost-free flooding and spamming, but it doesn't act as an unlocking puzzle that takes t time to solve/decrypt.

So KryptDisk relies on a Dingo node block-height beacon from a Dingo client to establish intervals of time. Preferably more than one, as a network's trust is built on the distribution of events and a consensus of facts rather than any single source.


0:00
/0:59

K▲Ʞ 1.44 Messaging demo

If you find any of this intriguing, feel free to download and explore. All participation will help test the software and potentially contribute to building a sustainable, decentralised time-locking encryption utility.

A reward layer may be added in a future version to compensate nodes that help strengthen the network.

KryptDisk remains a public beta and has not yet undergone an independent security audit.

Privacy is the right to the self.
— Edward Snowden