How to determine what encryption is being used a LUKS partition

cryptsetupencryptionlukspartition

What command can be used to determine the used encryption on a LUKS partition (all the relevant information, initialization vector, generation scheme, mode of operation and block cipher primitive)?

Best Answer

If the decrypted volume is /dev/mapper/crypto then you can get the information with

dmsetup table crypto
0 104853504 crypt aes-cbc-essiv:sha256 000[...]000 0 254:2 4096

If the encrypted volume is /dev/storage2/crypto then you get the information with

cryptsetup luksDump /dev/storage2/crypto
LUKS header information for /dev/storage2/crypto

Version:        1
Cipher name:    aes
Cipher mode:    cbc-essiv:sha256
Hash spec:      sha256
[...]
Related Question