-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Locking LUKS device: Not authorized #227
Comments
The permissions are defined using polkit rules, see Permissions. It's possible to give yourself only unlocking but no unlocking authorization. It also plays a role from which seat (ssh/tty/desktop/systemd) you unlock/lock the device. If you lock/unmount a device from a different seat than was used to lock it, you may need the On the other hand, it could also be that udisks has misjudged whether the unlocked device is e.g. a system-internal device or external device. In any case, it doesn't look like a udiskie issue to me. You can check whether you can lock/unlock using udisksctl:
I expect the same problem will occur. If you need further insight, keep another terminal window open while un-/locking with the following command running:
|
Oh wait, I didn't fully read through your post. So your situation is that first you unlock+mount the USB drive as root as part of your boot process, and then later try to lock it as user using udisks? In that case it's not surprising that this won't with default permissions. You definitely also need at least the |
Another possibility that may prevent locking even in case of sufficient authorizations is if your device is known in |
This didn't work for me on a Linux Mint. I'm using Udiskie because Lightdm and hence Thunar keeps crashing. |
I have an encrypted laptop (Arch Linux), with LUKS encrypted /boot partition on an USB stick. After booting I'm usually removing the USB stick. I can unmount and close the LUKS partition on the USB stick via a root terminal before that, but because I'm lazy, and because udiskie already seems to have the functionality, I'd like to use udiskie tray app for that.
However, when I click the 'Lock /dev/sdb1', I get the following error:
When I plug the USB stick back in, udiskie mounts it and asks for the LUKS passphrase, and then unlocks the partition. Just as it is supposed to do...
How come udiskie has permissions to unlock a device, but not to lock it? Is this an udiskie issue, or should I make some adjustments somewhere to my system?
The text was updated successfully, but these errors were encountered: