Secret-Keeper

Envelope encryption with strong cryptography and key management. A SecretKeeper encrypts a data encryption key (DEK) with a key-encryption-key (KEK), returning a WrappedKey. This crate (and sub-crates) implement several SecretKeepers, plus three content encryption ciphers:

The APIs in this crate are intended to provide good security practices while minimizing opportunities for unintentional developer errors that could reduce the security. One such principle is that encryption keys are always stored encrypted at rest.

Some SecretKeeper implementations have already been developed. If you create a new one, please send me a link and I'll link to it from here.

Implementation notes

Crypto algorithms used are implemented by other packages, notably RustCrypto, a pure-rust implemenation.

LZ4 compression is a pure rust implementation by lz_fear.

The concept for this library is based on the google cloud secret-keeper library

Status

This is a new crate and it should be considered alpha quality.

Additional SecretKeeper implementations are planned. If you create any, please let me know and I'll link to it from here.

The core secret-keeper library compiles into wasm without error, but I haven't tested it in a browser yet.