Improvements to backup and automation with server-side encryption #38113
Open
Description
How to use GitHub
- Please use the 👍 reaction to show that you are interested into the same feature.
- Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
- Subscribe to receive notifications on status change and new comments.
Is your feature request related to a problem? Please describe.
At present, server-side encryption on nextcloud has some drawbacks:
- There isn't an easy way to restore backed up files. It isn't enough to just copy back files and the private key, you also need to modify the database, which at present isn't documented
- Because of this, automated testing of a backup is a fairly large job - and if you don't go through this process you won't be certain that your file will be accessible if something goes wrong.
- It isn't clear how to ensure Nextcloud uses a consistent encryption key (e.g one I create once, either using
occ
or externally with gpg, and put in place in my orchestration), this means a much more convoluted orchestration process to ensure that I copy a key generated remotely to a safe location, and increases the difficulty of the above processes. - Because of this, confidence in server-side encryption is low and the feature, I believe, is under-utilised.
Describe the solution you'd like
- Document any DB changes required to restore an individual file and an entire instance.
- Document what needs to be done to use a pre-generated master / user key (e.g where do you need to copy it to, what DB do you need to change to use that key, etc)
- Add an
occ
tool to decrypt a single file outside of the nextcloud file structure (where the file isn't in any DB table) - Add an
occ
command to use a previously generated master / user key
Describe alternatives you've considered
- A very expensive process to test a nextcloud backup where I restore the entire system and check
the files are accessible. - An alternative but less useful encryption process (like a LUKS encrypted volume for a Docker container)
- Not using encryption at all
Activity