libcryptsetup kernel feature detection fails on boot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Since cryptsetup 1.6.5, libcryptsetup fails to detect the kernel's
features on boot. In particular, whenever the dm-crypt module is not
loaded before configuring a mapping with libcryptsetup, the
allow_discards option is not used.

# rmmod dm_crypt

# /usr/lib/systemd/systemd-cryptsetup attach test /dev/loop0 none
allow-discards,tries=0
Please enter passphrase for disk test! ****
Set cipher aes, mode xts-plain64, key size 256 bits for device /dev/loop0.

# cryptsetup status test
/dev/mapper/test is active.
  type:    LUKS1
  cipher:  aes-xts-plain64
  keysize: 256 bits
  device:  /dev/loop0
  loop:    /tmp/testfile
  offset:  4096 sectors
  size:    405504 sectors
  mode:    read/write

# /usr/lib/systemd/systemd-cryptsetup detach test

# /usr/lib/systemd/systemd-cryptsetup attach test /dev/loop0 none
allow-discards,tries=0
Please enter passphrase for disk test! ****
Set cipher aes, mode xts-plain64, key size 256 bits for device /dev/loop0.

# cryptsetup status test
/dev/mapper/test is active.
  type:    LUKS1
  cipher:  aes-xts-plain64
  keysize: 256 bits
  device:  /dev/loop0
  loop:    /tmp/testfile
  offset:  4096 sectors
  size:    405504 sectors
  mode:    read/write
  flags:   discards

The culprit seems to be dm_check_versions() in lib/libdevmapper.c - the
version number returned here differs when dm_crypt is not loaded.

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
dm-crypt mailing list
dm-crypt@xxxxxxxx
http://www.saout.de/mailman/listinfo/dm-crypt

[Index of Archives]     [Device Mapper Devel]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux