2020-06-25 12:00:37 +02:00
|
|
|
# Project Lazarus
|
|
|
|
|
|
|
|
Project Lazarus is a rock solid encryption-suit.
|
|
|
|
|
|
|
|
## Architecture:
|
|
|
|
|
|
|
|
### The Key Scheduler
|
|
|
|
|
|
|
|
We take in a password and a nonce and hash them to get the seed for our key scheduler.
|
2020-06-25 12:15:49 +02:00
|
|
|
The key scheduler takes this seed and
|
|
|
|
a) uses it to initialise an Eliptic-Curvce-Based RNG, which will later give us our eccState
|
|
|
|
b) hashes it using SHA3_256 to give us our hashState
|
2020-06-25 12:00:37 +02:00
|
|
|
every step the key scheduler performs a step operation on the EC, which gives us ou new eccState
|
|
|
|
and hashes the old hashState together with this eccState to give us our next hashState.
|
|
|
|
To generate a key from the state, the state is multiplied with a large number, then modulated.
|
|
|
|
Finally it is (in most cases) hashed again with SHAKE_256 to allow for variable-length keys.
|
|
|
|
|
|
|
|
### The Alpha Layer (AES)
|
|
|
|
|
|
|
|
In the Alpha-Layer we take our plaintext and encrypt it using a key and an iv both generated by our key scheduler.
|
|
|
|
|
|
|
|
### The Psi Layer (HMAC)
|
|
|
|
|
|
|
|
In the Psi-Layer we generate an HMAC of the Alpha-Ciphertext using two keys taken from our key scheduler.
|
|
|
|
|
2020-06-25 12:15:49 +02:00
|
|
|
### The Omega Layer (ChaCha20)
|
2020-06-25 12:00:37 +02:00
|
|
|
|
|
|
|
In the Omega-Layer we encrypt the Psi-Ciphertext using salsa2020, which we apply in cbc, in order to prevent any
|
2020-06-25 12:15:49 +02:00
|
|
|
patterns to remain in the final ciphertext. (We also encrypt the HMAC this way; just to be sure). The key and iv for
|
|
|
|
ChaCha20 and the iv for cbc are given to use by our fancy key scheduler.
|
|
|
|
|
2020-06-25 12:00:37 +02:00
|
|
|
Optionally a GZIP based compression can be applied.
|
|
|
|
|
|
|
|
|
2020-06-25 12:15:49 +02:00
|
|
|
## The dark secret:
|
2020-06-25 12:00:37 +02:00
|
|
|
Look into bethany.py
|