Closed joncrangle closed 1 month ago
I would think this covers the majority of use cases but I'm not that familiar with other encryption providers that would fit well with our use case.
This doesn't cover some of the more advanced scenarios like if someone wants to use a passphrase or symmetrical encryption, or if someone is using a hardware token (like a yubikey), but I think this keeps us with a sane default and alternatives.
The simplified encrypt
and decrypt
functions in https://github.com/MLFlexer/resurrect.wezterm/pull/35 will also make it easier for someone to provide their own functions or to create a PR if more features are desired.
EDIT: https://github.com/MLFlexer/resurrect.wezterm/pull/35 moves some of the encrypt
and decrypt
code elsewhere, so we should probably wait on this PR until the other PR is settled and I make the necessary updates here.
Since the encrypt and decrypt functions have grown in complexity, it was starting to get a bit difficult for someone to provide their own functions while also properly handling errors, input size and emitters.
This PR adds support for
rage
andgpg
by allowing the user to specify the provider in theirresurrect.set_encryption()
config like:It doesn't remove the ability for someone to provide their own functions for an advanced user. I noticed this PR kind of negated the need for a separate
encryption.md
so I pulled some of its content into the mainREADME.md
.