[pkg-cryptsetup-devel] cryptsetup failed with code 22 invalid argument
Miranda Zhang
miranda.zhang at instaclustr.com
Tue Jul 7 07:16:35 BST 2020
> you might have more modules missing. Assuming the cryptsetup binary
> comes from Debian the default cipher/mode/IV is aes-ats-plain64, are
> these modules available and loaded to? You will probably need aes, xts
> and ecb (or aesni), maybe more, see /proc/crypto.
I have loaded xts and aes_generic
modprobe aes_generic
modprobe xts
[image: Screen Shot 2020-07-07 at 3.54.58 pm.png]
Is this a stock Debian kernel or do you build your own?
>
I think it is a stock one
$ uname -r
4.9.0-12-amd64
[image: Screen Shot 2020-07-07 at 4.05.57 pm.png]
> To see if the culprit is with cryptsetup or something else, you can even
> try to map a test device manually using the same ciphers/mode/IV:
>
> dd if=/dev/zero bs=1M count=64 of=/tmp/disk.img
> losetup -f /tmp/disk.img
> dev=/dev/loop0 # loop device allocated above
> dmsetup create testcrypt --table "0 $(blockdev --getsz $dev) crypt
> aes-xts-plain64 $(xxd -l64 -c256 -ps </dev/urandom) 0 $dev 0"
>
> Does that work? (Is a new block device /dev/mapper/testcrypt being
> created?)
seems block device testcrypt gets created fine
[image: Screen Shot 2020-07-07 at 3.51.34 pm.png]
> If it does then the problem is with cryptsetup itself,
> otherwise it's something lower level.
>
> --
> Guilhem.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-cryptsetup-devel/attachments/20200707/b38eca90/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2020-07-07 at 4.05.57 pm.png
Type: image/png
Size: 57815 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-cryptsetup-devel/attachments/20200707/b38eca90/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2020-07-07 at 3.51.34 pm.png
Type: image/png
Size: 430586 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-cryptsetup-devel/attachments/20200707/b38eca90/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2020-07-07 at 3.54.58 pm.png
Type: image/png
Size: 327686 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-cryptsetup-devel/attachments/20200707/b38eca90/attachment-0002.png>
More information about the pkg-cryptsetup-devel
mailing list