Skip to content

Commit 2e9642f

Browse files
committed
rage-mount: Add support for mounting an encrypted file
This behaves similarly to `mount --bind source_file target_file`, except that `source_file` is transparently decrypted, and `target_file` is created as a symbolic link instead of a bind-mount. Part of #188.
1 parent 9c56470 commit 2e9642f

File tree

5 files changed

+355
-11
lines changed

5 files changed

+355
-11
lines changed

Cargo.lock

+84-5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rage/Cargo.toml

+4-1
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,12 @@ rust-embed = "5"
5757
secrecy = "0.7"
5858

5959
# rage-mount dependencies
60+
ctrlc = { version = "3.1.7", optional = true }
6061
fuse_mt = { version = "0.5.1", optional = true }
6162
libc = { version = "0.2", optional = true }
63+
nix = { version = "0.18", optional = true }
6264
tar = { version = "0.4", optional = true }
65+
tempfile = { version = "3.2", optional = true }
6366
time = { version = "0.1", optional = true }
6467
zip = { version = "0.5.9", optional = true }
6568

@@ -71,7 +74,7 @@ man = "0.3"
7174

7275
[features]
7376
default = ["ssh"]
74-
mount = ["fuse_mt", "libc", "tar", "time", "zip"]
77+
mount = ["ctrlc", "fuse_mt", "libc", "nix", "tar", "tempfile", "time", "zip"]
7578
ssh = ["age/ssh"]
7679
unstable = ["age/unstable"]
7780

rage/i18n/en-US/rage.ftl

+1
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ info-mounting-as-fuse = Mounting as FUSE filesystem
134134
err-mnt-missing-filename = Missing filename.
135135
err-mnt-missing-mountpoint = Missing mountpoint.
136136
err-mnt-missing-types = Missing {-flag-mnt-types}.
137+
err-mnt-must-be-file = Mountpoint must be a file.
137138
err-mnt-unknown-type = Unknown filesystem type "{$fs_type}"
138139
139140
## Unstable features

0 commit comments

Comments
 (0)