Patch for losetup

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

 



Many have talked about adding AES/Rijndael to losetup, but it
seems like this still not is done. I've
added this capability to util-linux 2.10o with the patch in
kerneli 2.2.18.int3, and I have also added definition of AES
to loop.h in the kernel. These changes are trivial and shoud
be added in the next verion of kerneli. Pathes follows

In mount/lomount.c in util-linux:

--- lomount.c.orig      Sat Dec 30 01:56:28 2000
+++ lomount.c   Sat Dec 30 16:53:48 2000
@@ -53,6 +53,8 @@
        { LO_CRYPT_DES_EDE3, "DES_EDE3",24},
        { LO_CRYPT_DFC, "dfc",16 },
        { LO_CRYPT_IDEA, "idea",16},
+       { LO_CRYPT_RIJNDAEL, "rijndael", 16},
+       { LO_CRYPT_AES, "aes", 16},
        { -1, NULL,0   }
 };

@@ -267,6 +269,8 @@
        case LO_CRYPT_RC6:
        case LO_CRYPT_DES_EDE3:
        case LO_CRYPT_DFC:
+       case LO_CRYPT_RIJNDAEL:
+       case LO_CRYPT_AES:
                pass = getpass("Password :");
                strncpy(passwdbuff+1,pass,PASSWDBUFFLEN-1);
                passwdbuff[0] = 'A';

And in include/linux/loop.h in the kernel:

--- loop.h.orig Sat Dec 30 01:53:23 2000
+++ loop.h      Sat Dec 30 01:54:15 2000
@@ -106,6 +106,7 @@
 #define LO_CRYPT_DFC      15
 #define LO_CRYPT_RIJNDAEL 16
 #define LO_CRYPT_RC5      17
+#define LO_CRYPT_AES      18
 #define MAX_LO_CRYPT   20

 #ifdef __KERNEL__


--
Gisle Sælensminde ( gisle@xxxxxxxxx )

With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea. It is hard to be sure where they are going
to land, and it could be dangerous sitting under them as they fly
overhead. (from RFC 1925)


Linux-crypto:  cryptography in and on the Linux system
Archive:       http://mail.nl.linux.org/linux-crypto/


[Index of Archives]     [Kernel]     [Linux Crypto]     [Gnu Crypto]     [Gnu Classpath]     [Netfilter]     [Bugtraq]
  Powered by Linux