Prerequisites
opensslmust be installed on the snapr host and available inPATH. snapr shells out to it for encryption.- snapr runs
openssl enc -<cipher> -salt -pbkdf2 -pass env:.... It forwards the password through an environment variable, never on the command line.
Fields
Example
snapr.yaml
.enc to the compressed filename (for example backup.tar.gz.enc). After a successful run, it deletes the plaintext archive from the working directory.
Decrypt an archive by hand
snapr encrypts with-salt -pbkdf2, so your decrypt command must include -pbkdf2 as well.
1
Get the encrypted file
Download the archive from the web UI, the download API, or copy it straight off the storage backend. If the job also uses the splitter, reassemble the parts first.
2
Export the passphrase
Put the passphrase in an environment variable so it never appears in your shell history as a command argument:
3
Decrypt
Use the same cipher the job was configured with. With the default If you set a non-default
aes-256-cbc:cipher in the job config, pass that same value here.4
Extract
Forgetting
-pbkdf2 on decrypt produces a “bad decrypt” error even with the correct passphrase, because OpenSSL then
derives the key with a different function than snapr used.