Author: sin <email@example.com>
Date: Thu, 16 May 2019 14:19:41 +0300
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/DESIGN b/DESIGN
@@ -24,18 +24,19 @@ bottom these are as follows:
The generic layer is the one that client code interfaces with. It is
the top level entrypoint to the block layer. The generic layer
-calculates the hash of the block and passes it down to the storage
-layer when writing a new block.
+calculates the hash of the block and passes it down to the compression
The compression layer will prepend a compression descriptor to the
block and then compress the block using snappy or lz4. It is possible
to disable compression in which case a special descriptor is prepended
-and the data is passed uncompressed to the layer below.
+and the data is passed uncompressed to the encryption layer.
The encryption layer will prepend an encryption descriptor to the
block and then encrypt/authenticate the block using XChaCha20 and
Poly1305. It is possible to disable encryption in which case it acts
-as a bypass with a special type of encryption descriptor.
+as a bypass with a special type of encryption descriptor. The block
+is then passed to the storage layer.
The storage layer will prepend a storage descriptor and append the
descriptor and the data to a single backing file.