How protection works
This page describes what happens to a file and its key, step by step, so that you can judge the design for yourself.
Protecting a file on the device
Used by the command-line tool, and by the browser when Settings say On the user's device.
- The device asks the installation for its two public keys: one for receiving file keys, one for checking signatures.
- The device makes a random 256-bit file key and a file ID.
- It wraps the file key to the installation's receiving key, bound to that file ID. Only the installation can unwrap it.
- It sends the wrapped key and the file's header: the file ID, the installation's address and ID, and the algorithms used. Not the file.
- The installation unwraps the key, seals it for storage, records the file and its owner, signs the header and returns the signature.
- The device checks that signature against the installation's signing key, then encrypts the file and writes the
.gvf.
In the browser this runs as WebAssembly that ships with the server. It is the same code as the command-line tool, compiled for the browser.
Protecting a file on the server
The browser sends the file over the TLS connection. The server makes the key, encrypts, stores the .gvf, and discards the readable copy. Nothing readable is written to storage.
Opening with the command-line tool
- The tool reads the header and checks the installation's signature. A file whose header was altered, or that names a different installation, is refused before anything is sent.
- It makes a one-time key pair and asks the installation for the file key, sending the public half.
- The installation checks who is asking, whether the file is shared with them, whether it is revoked, the Download original permission, the dates and the count. It records the request.
- It returns the file key wrapped to the one-time key, bound to the file ID and marked as going to a recipient, so a captured reply cannot be replayed in the other direction or for another file.
- The tool unwraps and decrypts on the device.
Opening in the browser
See Document viewer. The server decrypts and hands the content to the viewer for one session.
There are no per-user keys
People are identified by their account, not by a key they hold. The installation holds the keys and decides each request. This is what makes revocation immediate, lets limits be counted, and lets a document be shown in a browser with nothing installed. The price is stated plainly on the next page: your server is able to read your files.
What each party can see
| Party | Sees |
|---|---|
Someone holding only a .gvf | The installation's address and ID, the file ID, when it was made, its approximate size. Not the name, not the content. |
| Your file store | The same, for every stored file. |
| Your keys database | Sealed keys, useless without the root key. |
| Your server, while running | Everything it is asked to open. |
| The vendor | Nothing. |