cryptomator / cryptofs

Java Filesystem Provider with integrated encryption
GNU Affero General Public License v3.0
94 stars 35 forks source link

Feature/#88 improve backup strategy #90

Closed infeo closed 4 years ago

infeo commented 4 years ago

This PR closes #88

The backup strategy is now altered by only throwing an exception, if the masterkey file cannot be read. All other errors (comparsion with backup file, corrupt backup file, etc) are only logged on WARN level, but do not throw an exception.

The thought behind it is, that the backup strategy is only a best-effort attempt and for an application it is more important getting access to encrypted data rather than having a backup.

Additionally the method is renamed to better show its functionality.

cryptobot commented 4 years ago

Codacy Here is an overview of what got changed by this pull request:


Complexity decreasing per file
==============================
+ src/main/java/org/cryptomator/cryptofs/common/MasterkeyBackupHelper.java  -1

See the complete overview on Codacy