Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 34985

Summary: sys-apps/util-linux-2.12-r1 - losetup cant get option -k but requied it
Product: Gentoo Linux Reporter: Sergiy Borodych <Sergiy.Borodych>
Component: [OLD] UnspecifiedAssignee: Brad House <brad>
Status: VERIFIED DUPLICATE    
Severity: normal    
Priority: High    
Version: 1.4   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Sergiy Borodych 2003-12-03 09:53:06 UTC
After upgrade util-linux from util-linux-2.12 to util-linux-2.12-r1
root@work portage # /sbin/losetup -e aes-cbc /dev/loop0 /dev/hda4
You must specify a key size (in bits) for use with CryptoAPI encryption.
root@work portage # /sbin/losetup -e aes-cbc -k 256 /dev/loop0 /dev/hda4
/sbin/losetup: invalid option -- k
usage:
  /sbin/losetup loop_device                                      # give info
  /sbin/losetup -d loop_device                                   # delete
  /sbin/losetup [ -e encryption ] [ -o offset ] loop_device file # setup
Comment 1 Brad House 2003-12-03 10:28:39 UTC
The proper way to do this as of 2.12 with the cryptoapi
patches is to use
-e aes-cbc-256
instead of using -k.  
You must also use 'hashalot' to generate your key,
such as
rmd160 | /sbin/losetup -e aes-cbc-256 /dev/loop0 /dev/hda4

Also, 2.12 did not have any crypto api support at all or
the -k support, so you MUST have been using 2.11z before
then for any sort of crypto support.

-Brad

Comment 2 Jan Schubert 2003-12-06 02:37:05 UTC
See also Bug 25192, this one might be an duplicate
Comment 3 Brad House 2003-12-06 08:38:51 UTC
yep, is dup

*** This bug has been marked as a duplicate of 25192 ***
Comment 4 Sergiy Borodych 2003-12-09 23:28:08 UTC
Thanks 
it help me under gentoo-sources-2.4.20-r9
/sbin/losetup -e aes-cbc-256 /dev/loop0 /dev/hda4

Comment 5 Sergiy Borodych 2003-12-10 01:01:52 UTC
After installing gentoo-sources-2.4.22-r1
I can't find 
root@work src # modprobe cryptoloop
modprobe: Can't locate module cryptoloop
(I run genkernel --config and can't find like it options)
And I can't use my crypto fs
root@work src # /sbin/losetup -e aes-cbc-256 /dev/loop0 /dev/hda4
Password:
ioctl: LOOP_SET_STATUS: Invalid argument
root@work src # /sbin/losetup -e aes-256 /dev/loop0 /dev/hda4
Password:
ioctl: LOOP_SET_STATUS: Invalid argument
Comment 6 Sergiy Borodych 2003-12-10 02:08:32 UTC
after aplied patch-cryptoloop-jari-2.4.22.0 on gentoo-sources-2.4.22-r1 
all works
Why this patch not include in gentoo-sources-2.4.22-r1 ???