Skip to content

A command-line utility which allows you to work with directories encrypted using rclone.

License

Notifications You must be signed in to change notification settings

br0kenpixel/rclone-rcc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rclone Crypt CLI

rclone crypt CLI is a command-line utility which allows you to work with directories encrypted using rclone. It support over 10 commands (cat, copy, move, etc.)

I'm using a custom fork of Hidendra/rclone-crypt-rs which allows encrypting and decrypting files easily using a Read-like interface.

Example usage

# List a directory
rcc ls path/to/encrypted/dir mypass123 mysalt123

# Copy a file from an encrypted directory
rcc cp path/to/encrypted/dir some/encrypted/file.txt ~/Desktop/file.txt mypass123 mysalt123

# Copy a file into an encrypted directory
rcc cp path/to/encrypted/dir some/encrypted/file.txt ~/Desktop/file.txt mypass123 mysalt123 --reverse

# Unix-line cat command
rcc cat path/to/encrypted/dir some/encrypted/file.txt mypass123 mysalt123

# ...and more

Cross-compilation

Cross-compilation is possible, as long as you're not trying to compile with the mount feature enabled.

Supported commands

  • cat
    • A unix-like cat command.
  • cp
    • Copy files from/into encrypted directories
  • head
    • A unix-like head command.
  • ls
    • List files inside an encrypted directory
  • move
    • Move files from/into encrypted directories
  • read
    • Similar to cat but allows specifying an start offset and an amount.
  • rm
    • Deletes files
  • sizeof
    • Counts the size of an encrypted file (files are decrypted first)
  • size
  • tail
    • A unix-like tail command.
  • touch
    • A unix-like touch command.
  • mkdir
    • Creates directories
  • cryptdecode
    • Same as rclone's cryptdecode.
    • Notes: Unlike rclone, this command does not require a path (or in fact any kind of access) to the encrypted directory. It just needs the password and (optionally) the salt.
  • obscure
  • reveal
    • Reveals an obscured password.
  • lsd
  • mount
    • Requires feature mount to be enabled when building.
    • Requires Unix-based OS.
    • Allows mounting encrypted folders as virtual drives using FUSE.
    • Notes: A custom fork of fuse-rs and libfuse-sys are being used since the original crates use an outdated version of bindgen which causes compilation errors on macOS.

Limitations

  • Currently it is not possible to copy/move files between two encrypted directories. If you want to do this, you need to temporarily copy/move said file to a location outside the encrypted directory, then copy/move it into the destination (encrypted) directory.
    • Example:
    rcc cp first/encrypted/dir some/encrypted/file.txt /tmp/file.txt mypass123 mysalt123
    
    rcc cp second/encrypted/dir some/encrypted/file.txt /tmp/file.txt mypass123 mysalt123 --reverse
  • Since I'm not yet sure about the stability of mounts, the FUSE driver does not allow write operations for now. But write support is definitely planned.

About

A command-line utility which allows you to work with directories encrypted using rclone.

Topics

Resources

License

Stars

Watchers

Forks

Languages