If a user connects an usb-disk Nautilus shows this disk and allows the user to mount the disk by just clicking on it.
I am looking to achieve the same behavior with encrypted disks. Each disk is encrypted with the same key and the keyfile is distributed to all computers.
I have written an udev rule which does the cryptsetup luksOpen for the disk. This works fine.
But unfortunately Nautilus still detects the encrypted disk and asks the user for a password. And it does not detect the mapped and decrypted device.
How can I inform Nautilus about the device after my udev-rule opened the disk? How can I suppress the password dialog for the encrypted disk?
/etc/fstab
add some lines referring to mapped devices mounting them on/media/somewehre
. So nautilus can use them to mount the devices. remember to usenofail
andnoauto
as options. It might do the job. – Ravexina Jun 16 '20 at 12:57gio mount
(for gvfs/user) ormount
(admin)? – user535733 Jun 16 '20 at 13:48KERNEL=="sd[a-z][0-9]", SUBSYSTEM=="block", ACTION=="add", RUN+="/usr/local/bin/usbmountcheck udev add $kernel $parent"
, and the script runs the cryptsetup. – valpo Jun 16 '20 at 14:02/etc
, but maybe it'll help you. – Tomislav Nakic-Alfirevic Aug 01 '22 at 20:17