ajkis / scripts

Ajki's scripts & guides
https://ajkis.github.io/scripts/
324 stars 91 forks source link

HOW TO: Encrypt files with rclone crypt #1

Open ajkis opened 7 years ago

ajkis commented 7 years ago

Before creating new rclone crypt make sure you have rclone remote ( Amazon Drive, Google Drive etc...) To create rclone remote type: rclone config Press n for New Remote Set name eg: acd ( for amazon drive ) Choose type of drive ( Amazon Drive, Google Drive, Dropbox etc... ) Leave client_id, client_secret empty. Proceed with authorization.

Once you have your rclone remote you can proceed with creation of crypt drive.

rclone config

Press n for New Remote Press 5 for Encrypt/Decrypt a remote Set name eg: acdcrypt Set path eg your original remote name + folder where encrypted files will be acd:/crypt Press 2 for standard encryption ( filenames and content ) Press Y to set your own password ( do not forget it ) Press Y to set your own salt password ( different from previous one, dont forget it ) Set 128 for password strength Confirm passwords and remote.

Now you can use rclone copy/sync/move commands to upload your files to encrypte drive. Example: rclone move /source path/ acdcrypt:/ -c --no-traverse --transfers=300 --checkers=300 --delete-after --log-file=/var/log/rclone-upload.log

The source path can be anything eg local files or existing mount ( for example if you want to switch from encfs encryption to crypt just set source path to match your encfs unencrypted drive ) ... if you are switching from encfs I would suggest usage of rclone copy: rclone copy /source path/ acdcrypt:/ -c --no-traverse --transfers=300 --checkers=300 --log-file=/var/log/rclone-upload.log

To mount your new acd crypt mount use: rclone mount --allow-non-empty --allow-other acdcrypt: /path/acdcrypt/ &

thomas126 commented 7 years ago

Hi there. I noticed you Switched from ENCFS to Crypt from Rclone. Any reasons why? How is the performance compared to ENCFS?

ajkis commented 7 years ago

Streaming wise more or less same, however crypt is by far more efficient when it comes to writing data as there is zero disk I/O's since encryption happens in memory during uploading.

p.s. The whole setup is much cleaner since you dont have any encrypted files on disk and you only need 1 mount.