grub/docs
Patrick Steinhardt 365e0cc3e7 disk: Implement support for LUKS2
With cryptsetup 2.0, a new version of LUKS was introduced that breaks
compatibility with the previous version due to various reasons. GRUB
currently lacks any support for LUKS2, making it impossible to decrypt
disks encrypted with that version. This commit implements support for
this new format.

Note that LUKS1 and LUKS2 are quite different data formats. While they
do share the same disk signature in the first few bytes, representation
of encryption parameters is completely different between both versions.
While the former version one relied on a single binary header, only,
LUKS2 uses the binary header only in order to locate the actual metadata
which is encoded in JSON. Furthermore, the new data format is a lot more
complex to allow for more flexible setups, like e.g. having multiple
encrypted segments and other features that weren't previously possible.
Because of this, it was decided that it doesn't make sense to keep both
LUKS1 and LUKS2 support in the same module and instead to implement it
in two different modules luks and luks2.

The proposed support for LUKS2 is able to make use of the metadata to
decrypt such disks. Note though that in the current version, only the
PBKDF2 key derival function is supported. This can mostly attributed to
the fact that the libgcrypt library currently has no support for either
Argon2i or Argon2id, which are the remaining KDFs supported by LUKS2. It
wouldn't have been much of a problem to bundle those algorithms with
GRUB itself, but it was decided against that in order to keep down the
number of patches required for initial LUKS2 support. Adding it in the
future would be trivial, given that the code structure is already in
place.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
2020-01-10 14:30:24 +01:00
..
man Implement syslinux parser. 2013-12-18 05:28:05 +01:00
autoiso.cfg * docs/autoiso.cfg: New file. 2013-10-27 20:34:24 +01:00
fdl.texi 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org> 2008-03-01 17:27:51 +00:00
font_char_metrics.png GRUB developper manual based on existing Internals section and 2011-04-03 15:30:28 +02:00
font_char_metrics.txt GRUB developper manual based on existing Internals section and 2011-04-03 15:30:28 +02:00
grub-dev.texi json: Import upstream jsmn-1.1.0 2020-01-10 14:12:12 +01:00
grub.cfg * docs/grub.cfg: Update. 2012-05-04 00:30:15 +02:00
grub.texi disk: Implement support for LUKS2 2020-01-10 14:30:24 +01:00
Makefile.am Fix make dist. 2012-02-28 12:58:57 +01:00
mdate-sh 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org> 2008-03-01 17:27:51 +00:00
osdetect.cfg * docs/osdetect.cfg: Add isolinux config to detected OSes. 2013-12-18 05:34:17 +01:00
texinfo.tex remove all trailing whitespace 2009-06-10 21:04:23 +00:00