I understand that the main goal was to protect files on external storage. But I think this goal comes up short. Nextcloud should also target to encrypt everything else server side. Especially thumbnails.
Files are already encrypted on the Nextcloud instance itself. Which kinda makes no sense, when only external storage was supposed to be encrypted. And makes even less sense since those file’s thumbnails are left unencrypted.
This is a pity, because in fact I as the administrator can not decrypt those files! At least not without modifying the code of Nextcloud to snoop on the passwords of those users. If I could, the “Optional” recovery option would kinda be pointless, wouldn’t it?
Furthermore this “snooping” would be illegal in my country and thus comes with a bigger hurdle to take than just looking at unencrypted files on my own server, which hardly is a legal issue.
Server side password-protected encryption is a LOT more secure than no encryption.
-
If the server is compromised:
a) The attacker needs to make changes to the code of Nextcloud to snoop future password entries and stay on the server/reconnect later. This makes the intrusion easier detectable
b) Only those accounts can be decrypted and become compromised that log in while the server is compromised. -
The administrator can not accidentally see user files he was not supposed to see.
-
An administrator that wants to decrypt the files needs to be knowledgeable and particular malicious to snoop the passwords. He can’t do this on a whim or because he was temporarily overwhelmed by his curiousness. It will have most likely legal implications for him, if it is found out later.
-
If the user starts to distrust the administrator, he can stop using the service, and if that administrator has not yet “acted” he will never get the required password. Making it possible to virtually instantly delete my account at any time by simply never again providing my password.
-
A data dump, getting in the wrong hands, like a backup, is secure as the required passwords are missing altogether.
I do not see any good reason to not also encrypt the thumbnails. It would come with a performance loss, but if I wanted performance, I would not enable encryption in the first place.
Also I think this recovery option is really misleading. It makes you think the Administrator has no access to the files, while he can see all your photos just fine. So unless you encrypt the thumbnails as well, this should be made more transparent to the user at least. And maybe the encryption could really be limited to external devices in this case, improving performance, as its kinda pointless anyway. But I sincerely hope instead you opt for also encrypting the thumbnails/contacts/appointments…
Ofc, full client side encryption would be even better, and the only “real protection” even against malicious & knowledgeable Administrators. But I see the limitations with usability and there are in fact already solutions for this with zero-knowledge encryption from the view of Nextcloud with this usability trade-of available. (https://cryptomator.org/ or https://www.boxcryptor.com/en for example)
I tell you this as I also was caught wrong-footed by the fact that thumbnails were left unencrypted. This was totally unexpected for me and occurred to me much later after setup/use/propagation to friends
PS:
I have disabled the preview function altogether for now. Which partially fixes the problem but comes with a big - in my view totally unnecessary - usability cost. But here also I am stuck at not being able to delete already created thumbnails. is it safe to just purge them? Or are there references in the database to be taken care of?