mirror of
https://gitlab.kit.edu/kit/scc/sys/mail/exim-encrypt-dlfunc.git
synced 2025-12-06 07:53:56 +01:00
Small README fixes
This commit is contained in:
12
README.md
12
README.md
@ -54,28 +54,28 @@ meson install -C build
|
||||
|
||||
Not every build of exim is able to load libraries at runtime. Please refer to the
|
||||
[documentation](https://www.exim.org/exim-html-current/doc/html/spec_html/ch-string_expansions.html)
|
||||
of the `${dlfunc{…}}` function for details. exim from the debian package `exim4-daemon-heavy` meets all the
|
||||
requirements.
|
||||
of the `${dlfunc{…}}` function for details. The Debian package [`exim4-daemon-heavy`](https://packages.debian.org/exim4-daemon-heavy)
|
||||
meets these requirements.
|
||||
|
||||
## Usage
|
||||
|
||||
There are currently two pairs of functions:
|
||||
There are currently two pairs of complementary functions:
|
||||
|
||||
Symmetric encryption that derives its key from an ASCII string:
|
||||
Symmetric encryption that derives a key from an ASCII string (aka a “password”):
|
||||
|
||||
* `sodium_crypto_secretbox_encrypt_password(password, cleartext) → ciphertext`
|
||||
* `sodium_crypto_secretbox_decrypt_password(password, ciphertext) → cleartext`
|
||||
|
||||
The generated key is only as strong as the provided password.
|
||||
|
||||
Public key encryption that uses a key pair that needs to be created beforehand:
|
||||
Public key encryption that uses a key pair which needs to be created beforehand:
|
||||
|
||||
* `sodium_crypto_box_seal(public key, cleartext) → ciphertext`
|
||||
* `sodium_crypto_box_seal_open(private key, public key, ciphertext) → cleartext`
|
||||
|
||||
The second pair needs a proper key pair in the correct format. This is what the
|
||||
`generate_encryption_keys` utility is for. Simply run it once to generate a pair. Be aware that every invocation will
|
||||
overwrite the previous key pair without confirmation! Please save both parts in a safe place before proceeding.
|
||||
overwrite the previous key pair file without confirmation! Make sure to store your production keys in a safe place.
|
||||
|
||||
```shell
|
||||
$ ./generate_encryption_keys
|
||||
|
||||
Reference in New Issue
Block a user