mhogomchungu / zuluCrypt

zuluCrypt is a front end to cryptsetup and tcplay and it allows easy management of encrypted block devices
https://mhogomchungu.github.io/zuluCrypt
Other
496 stars 61 forks source link

Encrypted volume mount options #206

Closed nilz3000 closed 1 year ago

nilz3000 commented 1 year ago

First of all, thanks for this app. I want to know if there is a way to pass cryptsetup and/or mount options with Open->Volume hosted in a file->Options? At first I wanted to pass some cryptsetup "--perf*" options (in various notations), but it failed, and I thought it was just for mount options. Now I'm using btrfs inside a container and want to pass "compress=zstd" but it's not possible either. I've also done some unsuccessful tests with common mount options like "rw" and different placements of commas. So could you please clarify how to use cryptsetup and mount options, or clarify what this field is for. Thanks in advance.

mhogomchungu commented 1 year ago

There is currently no way to pass options to cryptsetup when unlocking. Please be specific on what option(s) you would like to use when unlocking a volume so i can test using them.

It is possible to set file system options but only for approved options.

To set arbitrary file system's options, follows instructions from here.

nilz3000 commented 1 year ago

Thanks for your reply. My specific use case is that I want to mount an encrypted luks2 file that contains a btrfs file system. Since Linux 6.2, the default mount options for btrfs include "discard=async", which leads to metadata leaks that can only be prevented by passing "nodiscard". But "nodiscard" seems not to be supported by zuluCrypt. A nice extra would be the ability to set internal btrfs compression alg with "compress=". I also found the filter list and added "nodiscard","compress=" in "allowed_btrfs", which solved my issue (just tested zuluMount-cli). Cryptsetup options are not that important for me. Sorry for the confusion about that.