[systemd-bugs] [Bug 23196] Do not offer hibernate with encrypted swap
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Sat Oct 12 16:39:19 CEST 2013
https://bugs.freedesktop.org/show_bug.cgi?id=23196
Zbigniew Jedrzejewski-Szmek <zbyszek at in.waw.pl> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEEDINFO |NEW
--- Comment #33 from Zbigniew Jedrzejewski-Szmek <zbyszek at in.waw.pl> ---
(In reply to comment #32)
> And the setting has now migrated to systemd. Is this still a problem?
I think the issue is still valid, but before we add code to systemd, we need to
have a full picture of how this is supposed to work, supporting all cases:
1. no encryption -> hibernate OK
2. encryption with random key -> hibernate not OK
3. encryption with static key -> hibernate OK
I'd prefer not to add explicit configuration unless we really cannot make it
work otherwise. For encrypted devices udev has:
E: UDISKS_DM_TARGETS_COUNT=1
E: UDISKS_DM_TARGETS_LENGTH=624637274
E: UDISKS_DM_TARGETS_START=0
E: UDISKS_DM_TARGETS_TYPE=crypt
It would be necessary to "drill down", from the swap device, all the way to the
bottom. If any of the devices is encrypted with a random key, hibernation is
not possible. We could then check if the device has a random key by checking in
/etc/crypttab. Supporting crypt devices configured through other means would be
not supported (they would be ignored for the purposes of those checks).
BTW, I think that the checks as currently implemented in dk-p are overly
restrictive, because the kernel will always use the first partition in
/proc/swaps for hibernation, so there's no need to loop over devices.
As a temporary fix, with systemd, if you want to disable hibernation, it should
be enough to add 'HibernateMode=disabled' to /etc/systemd/sleep.conf.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-bugs/attachments/20131012/f857ad5b/attachment.html>
More information about the systemd-bugs
mailing list